Source profileQuality 83/100

techygarg/lattice/skills/atoms/context-anchoring/SKILL.md

context-anchoring

Manage per-feature living documents that capture decisions, constraints, and reasoning across AI sessions during active development. Scoped to feature-level work — design, implementation, bugfix, refactor — not for codebase-wide assessments or product-wide specifications (those define their own document lifecycles). Handles creating new context documents, loading existing ones, and enriching them with new decisions. Use when starting a new feature, resuming work, making technical decisions, reso

Source repository stars
170
Declared platforms
0
Static risk flags
0
Last source update
2026-07-06
Source checked
2026-08-04

Decision brief

What it does—and where it fits

Manage per-feature living documents that capture decisions, constraints, and reasoning across AI sessions during active development. Scoped to feature-level work — design, implementation, bugfix, refactor — not for codebase-wide assessments or product-wide specifications (those define their own document lifecycles).

Best for

  • Use when starting a new feature, resuming work, making technical decisions, reso

Not for

  • Tasks that require unconfirmed production actions or broad system permissions.
  • Environments where the pinned source and install steps cannot be inspected.

Compatibility matrix

Platform support, with evidence labels

PlatformStatusEvidenceWhat to check
CodexNot declaredNo explicit evidencePortability before use
Claude CodeNot declaredNo explicit evidencePortability before use
CursorNot declaredNo explicit evidencePortability before use
Gemini CLINot declaredNo explicit evidencePortability before use
Open the compatibility checker

Installation

Inspect first. Install second.

The source command is displayed only when detected. A safe inspection prompt is always available so your agent can explain every action before execution.

Source-detected install commandSource
npx skills add https://github.com/techygarg/lattice --skill "skills/atoms/context-anchoring"
Safe inspection promptEditorial

Inspect the Agent Skill "context-anchoring" from https://github.com/techygarg/lattice/blob/75b7e0728587f2e822e8cdbe11583a6f9a38a4b3/skills/atoms/context-anchoring/SKILL.md at commit 75b7e0728587f2e822e8cdbe11583a6f9a38a4b3. List every install step, command, network request, credential, file read/write, external action, and rollback step. Explain whether it fits my task. Do not install or execute anything until I approve.

Workflow

What the source asks the agent to do

  1. 01

    Scope

    Feature-level only — anchors decisions as a feature flows from design → implementation → bugfix → refactor.

    Feature-level only — anchors decisions as a feature flows from design → implementation → bugfix → refactor.
  2. 02

    Config Resolution

    Skill manage dir of per-feature context docs. Resolution order:

    Look .lattice/config.yaml in repo rootIf found, check paths.contextbase for custom dir pathIf custom path exist, use that dir for context docs
  3. 03

    Problem

    AI no persistent memory. Context decay real: by message 30+, early decisions contradicted, naming inconsistent, "why" evaporate. Damage compound -- forgotten decision become potential contradiction, lost constraint become violation, unresolved question become silent assumption.

    Feature-bound -- one doc per feature, scoped decisions onlyDecision-focused -- capture what, why, what-else-considered for every choiceAppend-only -- decisions never removed/rewritten, only added chronologically
  4. 04

    Document Lifecycle

    Three behaviors govern context anchor doc lifecycle. Each triggered reactively (user ask) or proactively (AI suggest). Both cases, AI always confirm before acting -- propose, user dispose.

    Three behaviors govern context anchor doc lifecycle. Each triggered reactively (user ask) or proactively (AI suggest). Both cases, AI always confirm before acting -- propose, user dispose.
  5. 05

    Status Lifecycle

    Every context doc carries a status frontmatter field. Never infer status from body prose.

    Every context doc carries a status frontmatter field. Never infer status from body prose.STOP: Check this field before acting on a context doc. draft ≠ approved. approved ≠ complete. Deviation from approved design: update doc and re-approve — no new status values.

Permission review

Static risk signals and limitations

No configured static risk pattern was detected

This is not proof of safety. Runtime behavior, indirect dependencies, and hidden external systems are outside the static scan.

Evidence record

Why each signal appears

EvidenceSourceComputedTestedEditorial
SignalValueEvidence typeMeaning
Quality score83/100ComputedDocumentation, specificity, maintenance, and trust rules
Repository stars170SourceRepository attention, not individual Skill quality
Compatibility0 platformsSourceDeclared in the catalog source record
Usage guideautomated source guideEditorialGenerated or reviewed according to the visible evidence level

Pinned source

Provenance and original SKILL.md

Repository
techygarg/lattice
Skill path
skills/atoms/context-anchoring/SKILL.md
Commit
75b7e0728587f2e822e8cdbe11583a6f9a38a4b3
License
MIT
Collected
2026-08-04
Default branch
main
View the original SKILL.md

Context Anchoring

Scope

Feature-level only — anchors decisions as a feature flows from design → implementation → bugfix → refactor.

Config Resolution

Skill manage dir of per-feature context docs. Resolution order:

  1. Look .lattice/config.yaml in repo root
  2. If found, check paths.context_base for custom dir path
  3. If custom path exist, use that dir for context docs
  4. If no config/path/path not found, use default .lattice/context/

Each feature get one doc at <context_base>/<feature-name>.md. No default principles, no overlay modes, no override files -- just thin template and per-feature docs that grow through enrichment.

Problem

AI no persistent memory. Context decay real: by message 30+, early decisions contradicted, naming inconsistent, "why" evaporate. Damage compound -- forgotten decision become potential contradiction, lost constraint become violation, unresolved question become silent assumption.

Context anchor docs solve:

  • Feature-bound -- one doc per feature, scoped decisions only
  • Decision-focused -- capture what, why, what-else-considered for every choice
  • Append-only -- decisions never removed/rewritten, only added chronologically
  • Session-spanning -- doc outlive conversation, carry context forward
  • Git-native -- live in repo, versioned alongside code

Two docs per feature: requirement doc (static, written upfront, not managed by this skill) and context anchor doc (living, evolving, managed by this skill). Requirement doc define what build. Context anchor doc capture how and why -- decisions, constraints, reasoning that emerge during development.

The requirement doc may live in this repo, or in whatever system the team already tracks requirements in (Jira, Linear, a wiki) -- this atom never writes to it regardless of where it lives.

Document Lifecycle

Three behaviors govern context anchor doc lifecycle. Each triggered reactively (user ask) or proactively (AI suggest). Both cases, AI always confirm before acting -- propose, user dispose.

BehaviorPurposeReactive TriggerProactive Trigger
CreateStart new context docUser ask create oneAI detect feature work beginning without doc
LoadRestore context from existing docUser ask load/resumeAI detect existing docs and suggest loading
EnrichAdd new decision, constraint, resolutionUser ask capture somethingAI detect decision made in conversation

Status Lifecycle

Every context doc carries a status frontmatter field. Never infer status from body prose.

ValueSet by
draftcontext-anchoring Create — design not yet complete
approveddesign-blueprint Step 3 — L1–L4 complete, design reviewed
completecode-forge Step 5 — implementation done

STOP: Check this field before acting on a context doc. draft ≠ approved. approved ≠ complete. Deviation from approved design: update doc and re-approve — no new status values.

Create Behavior

Always confirm before creating.

Steps:

  1. Identify feature name. Derive kebab-case filename from feature name (e.g., "User Authentication" → user-authentication.md). Confirm name with user.
  2. Ask about requirement doc. If user has a requirement document, capture it for the requirement_doc frontmatter field -- a local file path, or an external reference (URL, ticket ID, or other identifier resolvable via a connected MCP tool). If neither, leave null.
  3. Create dir if <context_base>/ not already exist.
  4. Generate from template. Read ./assets/feature-doc-template.md and fill in:
    • Frontmatter: feature, requirement_doc, created (today date), status: draft
    • H1 heading: feature name
    • Summary: one-line description (ask user or derive from context)
    • If template file not found, generate doc using this minimal structure:
      ---
      feature: <feature-name>
      requirement_doc: <local path, external reference, or null>
      created: <today's date>
      status: draft
      ---
      # <Feature Name>
      <one-line summary>
      ## Decisions Log
      | Date | Decision | Reasoning | Alternatives Considered |
      |------|----------|-----------|------------------------|
      ## Open Questions
      None.
      ## Constraints
      None.
      ## Key Files
      
  5. Confirm creation. Show user proposed path and content summary.

Load Behavior

Always confirm before loading.

Steps:

  1. Read context doc. Parse frontmatter and all sections.
  2. Resolve linked requirement doc if requirement_doc not null. Local path → read directly. External reference (URL, ticket ID, or other identifier) and a connected MCP tool can resolve it → attempt fetch. Neither applies → ask the user to paste the current requirement constraints directly -- expected, not an error. Use whatever is resolved to understand feature goals and scope, but not modify.
  3. Present structured acknowledgment (see Output Formats below):
    • Feature name and summary
    • Status (from frontmatter status field — surface explicitly)
    • Requirement doc status (linked or not linked)
    • Decision count and latest decision
    • Open questions (if any)
    • Constraints (if any)
  4. Honor all logged decisions. Every decision in log treated as active commitment. Never contradict logged decision without explicit discussion and new decision entry explaining change.
  5. Respect constraints as non-negotiable. Constraints harder than decisions -- represent boundaries that cannot be crossed without deliberate, documented override.
  6. Flag open questions when work touch them. If current task involve area with unresolved question, surface immediately. Not silently assume answer.

Enrich Behavior

Always confirm before writing.

What capture in Decisions Log:

  • Date -- when decision made
  • Decision -- what decided, stated clearly and concisely
  • Reasoning -- why this choice made, key factors
  • Alternatives Considered -- what else evaluated and why rejected

Rules:

  1. Append-only. New entries go bottom of Decisions Log table. Never modify or remove existing entries.
  2. Chronological order. Entries reflect order decisions made, not grouped by topic.
  3. Concise but complete. Each entry understandable on own without re-reading full conversation.
  4. Feature-bound only. Only capture decisions relevant to this specific feature. Cross-cutting concerns, project-wide conventions, general preferences belong elsewhere.
  5. Resolve open questions explicitly. When open question answered, add answer as decision in log and remove question from Open Questions list.
  6. Constraints non-negotiable. Once constraint recorded, it binding. Changing constraint require new decision entry explaining why constraint being revised.
  7. Constraint Override Protocol. If user explicitly say override constraint (e.g., "forget that constraint, we've changed direction"), not silently delete. Instead: (a) ask user confirm override explicitly, (b) strike through constraint in Constraints section (prefix with ~~), and (c) add decision entry in Decisions Log recording override and reasoning. Constraint history preserved; binding status revoked.
  8. Key Files dedup. When adding to the Key Files table, check if the path already exists in the table. If it does — skip.
  9. Cross-cutting check. After enriching, apply the learning-harvest cross-cutting test: (1) does it name a pattern or approach, not a feature-specific fact? (2) could a developer on a different feature apply it without knowing this feature's context? If both pass — silently add to the learning-harvest queue. Do not prompt the user here.

Document Discovery

When user ask load or resume but not specify which feature:

  1. Scan context base dir for .md files.
  2. Match by frontmatter feature field or by filename.
  3. If multiple docs exist, present numbered list with feature name, creation date, decision count. Let user choose.
  4. If only one doc exist, suggest loading it. Confirm before proceeding.
  5. If no docs exist, inform user and suggest creating one.
  6. Fuzzy match: If user term partially match multiple docs (e.g., "auth" matching user-authentication.md and oauth-authentication.md), show all partial matches with full filenames and let user choose. Never guess.

When user mention feature name in conversation, check if matching context doc exist. If it do and not been loaded in this session, suggest loading it.

Output Formats

Load: Show feature name, status (from frontmatter), requirement doc status, decision count, open questions, constraints, latest decision. Close with: "All logged decisions are active. Constraints are non-negotiable. I will flag open questions when work touches them."

Enrich: Show exactly what will be added (decision, reasoning, alternatives considered). Wait confirmation before writing.

Create: Show proposed path, feature name, requirement doc link. Wait confirmation before creating.

Integration with Other Skills

This atom composed by molecules that orchestrate feature workflows:

  • design-blueprint -- invoke Create or Load in Step 1 (Establish Context), then invoke Enrich at each design level checkpoint to capture decisions as they emerge
  • code-forge -- invoke Load in Step 1 (Establish Implementation Context) to load blueprint, then invoke Enrich throughout Steps 3-5 to capture implementation decisions, key files, resolved questions

When context doc active (loaded in current session), Enrich run continuously -- AI monitor conversation for decisions worth capturing and suggest enrichment as they arise. Not limited to molecule that loaded doc; any skill producing decisions can trigger enrichment suggestion.

Alternatives

Compare before choosing

Computed 10042,968

coreyhaines31/marketingskills

ab-testing

When the user wants to plan, design, or implement an A/B test or experiment, or build a growth experimentation program. Also use when the user mentions "A/B test," "split test," "experiment," "test this change," "variant copy," "multivariate test," "hypothesis," "should I test this," "which version is better," "test two versions," "statistical significance," "how long should I run this test," "growth experiments," "experiment velocity," "experiment backlog," "ICE score," "experimentation program

Computed 10042,968

coreyhaines31/marketingskills

churn-prevention

When the user wants to reduce churn, build cancellation flows, set up save offers, recover failed payments, or implement retention strategies. Also use when the user mentions 'churn,' 'cancel flow,' 'offboarding,' 'save offer,' 'dunning,' 'failed payment recovery,' 'win-back,' 'retention,' 'exit survey,' 'pause subscription,' 'involuntary churn,' 'people keep canceling,' 'churn rate is too high,' 'how do I keep users,' or 'customers are leaving.' Use this whenever someone is losing subscribers o

Computed 100165

JasonColapietro/suede-creator-skills

suede-ab-testing

Suede-owned experimentation discipline for hypotheses, sample sizing, test duration, significance, and repeatable experiment programs. Use when comparing variants, deciding whether a result is reliable, or building an experiment backlog and cadence. NOT FOR: analytics instrumentation (use suede-analytics), post-click conversion diagnosis (use suede-site-alchemy), or writing the variant copy itself (use suede-copy).

Computed 1007

narrative-io/narrative-skills-marketplace

design-analysis

Translate a fuzzy analytical question into a rigorous investigation plan. Interrogates the ask, grounds the plan in the available data dictionary, applies analytical best practices, and produces a structured brief of query specifications for a downstream query-writing skill. Plans, does not write SQL. Use when: "why did X drop", "is there a relationship between A and B", "who are our highest-value customers", "what's driving the change in Y", "investigate this trend", "design an analysis for", "