Skip to main content

Services overview

ServiceProjectPortOne jobOwns
Taxonomy APIKaleido.Taxonomy.Api8080Catalogue, taxonomy, tagging, similarity, MCP, and the front door for GREpublic schema, raw HTML
ActivityKaleido.Gre.Activity8081Store every transaction and session idempotently; serve per-game signalsactivity schema
SimulatorKaleido.Gre.Simulator8082Invent customers, replay or stream their play, measure accuracysimulator schema
ProfileKaleido.Gre.Profile8083Turn activity into per-customer, per-game affinities (batch)profile schema
RecommenderKaleido.Gre.Recommender8084Blend signals into a ranked, explained list; obey player protectionrecommender schema, in-memory catalogue
IngestKaleido.Gre.Ingest8085Keep live per-customer state in Redis from KafkaRedis c:*, cfg:ingest:*

Shared libraries (Contracts, Hosting, Telemetry, Stream) are described in Shared libraries, and the React front end in Web app.

Common patterns​

Every GRE service follows the same shape, which keeps them small and predictable.

PatternHow it shows up
Minimal API hostProgram.cs registers telemetry, the service key, the DbContext, typed HttpClients and hosted services, then maps endpoints.
/healthUnauthenticated 200 ok on every service.
Auto-migrateEF migrations run at start-up unless Db:AutoMigrate=false.
Settings as dataTunables live in a one-row settings table with a Revision that increments on every PUT /settings. A build records the revision it used.
Draft settingsEndpoints that score accept an unsaved draft of the settings in the body, so the UI can compare before saving. Drafts are never cached.
Background buildsPOST /builds returns 202 and enqueues an id on an in-process Channel. A BackgroundService works through builds one at a time. A second request while one is queued or running gets 409.
Build-tagged rowsEach build writes rows tagged with its id, then deletes rows from older builds at the end. Customers or links that disappeared drop out without a separate cleanup.
Restart safetyOn start-up, builds left Running or Queued are marked Failed with "Interrupted by a restart."
DELETE /dataResets what the service learned, for the simulation. A real feed never calls it.
Paged bulk readsCursor paging by key (after=<last id>), never offsets, so pages stay fast and stable.

Background workers​

ServiceWorkerTriggerDoes
Taxonomy APITaggingProcessorPolls every 2 s (100 ms while busy)Claims up to 3 queued tagging items and runs them against the AI provider
Taxonomy APIPipelineSamplerEvery second while a viewer is connectedSamples GRE services and broadcasts over SignalR
ProfileBuildWorkerPOST /buildsRebuilds every customer's affinities
RecommenderBuildWorkerPOST /builds or BuildSchedulerCatalogue build and crowd build
RecommenderBuildSchedulerEvery Builds:CheckSecondsStarts catalogue or crowd builds on their configured cadence
RecommenderCatalogueCacheEvery 15 sReloads the in-memory catalogue when a build finished or the day changed
RecommenderSuppressionCacheEvery 5 sReloads the player-protection list
IngestIngestSupervisorEvery 2 sStarts, replaces or stops one SourceConsumer per enabled ingestion
IngestSourceConsumerContinuousKafka batch to Redis to offset commit
SimulatorRunWorkerPOST /runsGenerates customers and posts their activity
SimulatorStreamRunnerPOST /streamsPublishes a simulated world to Kafka at a target rate