Architecture 

Overview 

AI Universe is a shared foundation layer:

Consuming Extension Code
        |
        v
  AiRequestService
        |
        v
     BaseClient
        |
        v
   Provider APIs
Copied!

Parallel support:

AiStatisticsService -> OpenAI Usage API -> Processed chart data cache
HttpAuthUtility    -> Protected URL fetching with optional Basic Auth
Copied!

Main components 

  • Request orchestration: AiRequestService
  • Provider adapters and payload composition: BaseClient
  • Statistics processing: AiStatisticsService
  • Engine configuration filtering: AiEngineConfiguration
  • Utility and environment helpers: AiUniverseUtilityHelper
  • HTTP auth helper: HttpAuthUtility

Configuration model 

Runtime behavior is mostly driven by extension configuration keys from ext_conf_template.txt.

This includes:

  • provider keys and models
  • default engine selection
  • token/temperature values
  • basic auth settings

Caching 

The extension registers cache nsaiuniverse_statistics in ext_localconf.php.

Statistics service stores processed data in this cache to reduce repeated usage API calls.

Constraints 

  • No native frontend plugin and no Fluid frontend output in this package.
  • Primary role is reusable service infrastructure.