karea_set_context
Write or update a titled entry in a task's cross-session context, preserving the full history of plans, findings, decisions, and attempts.
Instructions
Write a titled entry of the task's Context — the AI-facing cross-session working memory. Context tracks the FULL HISTORY of a task, not just its current state: what was tried, what worked, what failed, what was decided and why. Update incrementally so the journey is preserved (never overwrite the whole entry with "current status" — read first with karea_get_context, append/refine, then write back). Context is your DEFAULT save target: after every plan, finding, decision, or gotcha, persist it here proactively under titles like "Plan", "Findings", "Decisions", "Gotchas", "Attempted". Upserts by title: same title overwrites THAT entry only; other entries are untouched. Pass empty context to delete the entry. Use karea_add_note only for human-facing updates and karea_set_markdown for long-form docs — but keep Context up to date either way.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| task | Yes | Task name, visual ID (C1, T2), or UUID | |
| title | No | Entry title (e.g. "Plan", "Findings", "Decisions"). Defaults to "General". | |
| context | Yes | The full content for this entry. Pass empty string to delete the entry. | |
| toolType | No | Optional: your AI provider ("claude-code" / "opencode" / "codex" / "cursor" / "aider" / "other"). Required when aiSessionId is supplied. | |
| projectId | No | Project name or ID (needed for visual ID lookup) | |
| aiSessionId | No | Optional: your current AI CLI session ID. When paired with toolType, atomically links this session to the affected task (equivalent to calling karea_link_session, but saves the round-trip). For Claude Code use the id from `claude --resume`. | |
| sessionLabel | No | Optional short label for the linked session (e.g. "Feature draft"). |