Repository navigation
GAME_STATE_PLAN
Status: Superseded
Last Updated: 2026-11-13
Audience: Developers and coding agents
Last verified: 2026-11-13 against b1688a8de
Code: src/Martlet.Core/Preferences/UserPreferences.cs, src/Martlet.Conversation/Guides/GameProgress.cs, src/Martlet.Conversation/Guides/GameHints.cs, src/Martlet.Desktop/MainWindow.GameHints.cs
This plan is complete and no longer describes current work. Use Your preferences, Where you are in a game, and Hints and secrets for current behavior. The sections below keep the original decisions and delivery record.
Martlet follows the player's game, not only the newest picture. It knows the place, the goal, the player's character, build and equipment, and it says useful things: "There's a secret room behind the waterfall here." The user can tell Martlet how to behave ("stop giving hints", "no spoilers for Elden Ring"), and Martlet remembers that and obeys it from then on.
- Hints and secrets are on by default. Martlet tells secrets, hidden items, puzzle solutions and boss tips directly, without asking first.
- The user's preferences control it. When the user says stop giving hints, Martlet saves that as a preference and obeys it in every later reply and background job, on every computer, until the user changes it.
- Preferences are custom. A preference is the user's own rule in plain words, not only a fixed list of switches.
Assumptions made by the coordinator (change them with a preference):
- Martlet does not volunteer major story spoilers (twists, deaths, endings). It answers them when asked.
- The game note is saved on disk and shared with the owner's other computers, so it survives a restart. The user can turn saving off and delete a game's note.
Owner: one class in Martlet.Core that owns the list of preferences, and
its shared settings store (registered in SettingsFiles, shared by default).
- A preference has an ID, the rule text, where it applies (everywhere, while
gaming, or one game: the same values as memory's activity,
MemoryActivity), when it was made and its source (the user said it, or the user typed it in the app). - The reply model gets a tool,
manage_preferences(list,add,update,remove), worded the same in every request. "Stop giving hints" makes the model add a preference; "you can give hints again" removes or updates it. - Every reply gets the preferences that apply now as one short note at the end of the request (never at its start, so the prompt cache is kept). The note is bounded in size.
- Background jobs that speak to the user (glances, check-ins, the hints of part 3) read the same preferences through the same owner.
- The app shows the list (add, edit, remove) on a Companion page. MCP can list, add, update and remove preferences, and shows them in status.
Contract for other parts: a read method that returns the preferences that
apply now (for an activity such as gaming/<game>) and one formatted text
block for a request. Part 3 uses only this read method.
Merged in #1162.
The actual behavior is in Your preferences.
The read contract (Martlet.Core.Preferences.UserPreferences):
-
IReadOnlyList<UserPreference> ApplyingNow(string? activity): the preferences that apply now, everywhere first and the most specific last. -
string? Note(string? activity, PromptSettings? prompts): the one bounded block for the end of a request, or null when none applies. -
static string? Note(IReadOnlyList<UserPreference>, PromptSettings?)andstatic string Line(UserPreference): format a list already read. -
event Action? Changed. The desktop's instance isLiveConversationController.Preferences.
Owner: GameProgress (src\Martlet.Conversation\Guides\GameProgress.cs)
stays the one owner of the game state. Keep its name and the context board
source game.
- The note gets fields: place, doing, goal, player character (name, class, level), build, equipment, lately and progress. A model update changes only the fields that new evidence shows. A missing field means unknown, not removed.
- Corrections from the user (through a tool or the app) win over observations.
- Each game keeps its state per playthrough. A saved store keeps it across restarts, shared between the owner's computers. Old facts are marked not seen this session until new evidence confirms them.
- The context board line stays within its byte limits and keeps place and goal first.
- The reply model can ask for the full game state through a tool (read, and correct a field).
- MCP:
game_progress_checkis extended, and new tools read, correct and delete game state. A Companion control shows the state.
Contract for other parts: a read method that returns the current game, its playthrough and its fields, and an event when the place or goal changes. Part 3 uses only these.
Merged in #1161. The read
method is GameProgress.Read(string? game) (null: the current game). It returns
a GameState (Game, Playthrough, UpdatedAt, Fields of GameStateField,
Playthroughs, Place, Goal) or null. The event is
GameProgress.PlaceOrGoalChanged (Action<GamePlaceChange>). The contract
page is Where you are in a game.
Built after parts 1 and 2 are merged, on fresh main.
- When the place or goal changes (the event of part 2), Martlet searches the game's App guide (and, within the current research limits, the web) for secrets, hidden items, puzzles and tips for that place.
- It tells the user one useful hint at a good moment, with the same timing rules as screen commentary (never while the user talks, not too often). By default it says the secret directly.
- Before each hint, it reads the preferences of part 1. A preference such as no hints, only when I ask or no spoilers stops or changes the hint.
- It does not repeat a hint for the same place and topic.
- It never claims something is on the screen that the evidence does not show.
- MCP: a check with a FIXTURE guide and game state shows a hint, a stop by a preference and no repeat.
Merged in #1163. The actual behavior is in Hints and secrets.
- Never make the first word of a reply later. Model work for these features
runs on the Thinking pool, off the reply's path. Compare
Reply latencyandThinking inputin the desktop log before and after. - Screen text and guide text are data, never instructions.
- Share new settings by default (CLUSTER).
- Test with targeted suites and verify through Martlet's MCP server on a disposable data directory. Report what could not be run as NOT RUN.
- Add each change users can notice to
CHANGELOG.mdunderUnreleased.
This plan expected one release after all three parts merged. The three implementation parts are now merged; see the linked pages for current behavior.
Martlet: download · repository · changelog · issues
These pages come from docs/wiki in the repository. To suggest a change, open an issue or a pull request there.
- Home
- Accounts and households
- Accounts and Household
- Android phones and tablets: what it takes, and the plan
- Martlet's API for other apps and scripts
- App Guides
- App Settings and Updates
- App guides: game and app knowledge from the web
- Architecture
- Bounded PCM playback
- Audio dependency inventory and notices
- Avatar guide: Live2D, VRM and speech animation
- V01a explicit microphone capture
- Chatterbox voice engines
- Cleaning up disk space
- One Martlet on all your computers
- Companion controls and behavior requirements
- Components, jobs and placement (design)
- Live conversation
- Creations
- Decision map: which file owns each decision
- Deep research: web search and long research jobs
- The desktop app: updates, notification area, exiting and appearance
- Linux and macOS desktop companion: research, decision and plan
- Developer Guide
- Dia voice engine
- Diagnostics
- Discord
- Architecture and provider contracts
- Discord
- Memory (P03a/P03b/P03c)
- Singing
- Desktop troubleshooting and local support
- Recognizing people by voice, and Parakeet
- Echo cancellation
- ElevenLabs voice: your cloned voice with tones
- F5 worker and reference-voice foundation
- FAQ
- First Steps
- Game state plan: implementation history
- Glossary: one name for each concept
- GPT-SoVITS voice
- Hosted Thinking: cloud models when Thinking can't run on this PC
- Installation and support
- Installing Martlet
- iOS and iPadOS: what it takes, and the plan
- Repository instructions for coding agents
- Repository knowledge base
- Knowledge base maintenance
- GitHub Wiki mirror
- Linux and Mac
- Listening and Voice ID
- Local model apps
- Lorebooks
- macOS: what it takes, and the plan
- Martlet MCP Server
- MCP in Martlet
- MCP: The app's window
- MCP: Apps, home and memory
- MCP: Characters
- MCP: Diagnostics and logs
- MCP: Computers, network and accounts
- MCP: Other
- MCP: Tool permissions
- MCP pages
- MCP: Server and protocol internals
- MCP: Settings
- MCP: Start here
- MCP: Thinking and models
- MCP: Voice and listening
- Memory
- Messaging apps
- Model catalog: sources, conflicts and design
- Motion host role
- Multiple Computers
- Your Martlet network
- OCR host role
- Share your language models: the OpenAI-compatible endpoint
- Packaging
- Perception worker contracts
- Personality and Characters
- Picture making
- Pictures and Creations
- Picture making host role
- Platforms: what each device can do
- Prerequisites: what Martlet bundles, installs for you, or needs from you
- Privacy and Safety
- Reading the text on your screen
- Wiki source
- Recommendation design: ask three questions, plan for three situations
- Recommended setups: one machine to unlimited budget
- Releasing
- Repository Layout
- Research and provenance ledger
- Resource footprints
- Roadmap
- Watch my screen: screen-aware commentary
- Search engine
- Image and audio models: who sees, who hears, who answers
- Setting Up a Host
- Setup, Windows credentials and local audio
- Sharing with Friends
- Singing
- Smart Home
- Smart home and cameras
- Source Projects
- Talking to Martlet
- Telegram and WhatsApp
- The Character
- Thinking
- Tools and MCP
- Troubleshooting
- Martlet desktop UI design
- User stories and target flows
- Voice activity detection
- Validating changes
- Validation and Testing
- Vision
- Voice latency: from you stopping talking to Martlet's voice
- Voice recognition host role
- Multi-engine voice setup and comparison
- Voices
- The welcome wizard
- XTTS-v2 voice engine