Skip to main content
Glama

get_guideline

Assemble core guidelines, role-specific phase guidelines, and foundational ADRs for a designated agent role during a mid-session switch, preserving pipeline integrity.

Instructions

[SESSION TOOLS] Assembles and returns the full context bundle (core guidelines + role-specific phase guidelines + filtered foundational ADRs) for a named agent role, without reading or modifying session.md.

Use this for deliberate mid-session role switches when you already know the target role and do not want to disturb pipeline state. Do NOT use at session start — call get_session_context instead, which also injects the SESSION STATE block and the correct NEXT STEP directive.

Allowed role values: any role registered in the project's role_profiles.yaml (e.g. 'discovery', 'architecture', 'planning', 'execution'). Returns an error string listing valid roles if the value is unrecognised.

Returns: assembled markdown string (core guidelines + role guidelines + ADRs). Raises: error string if role is not registered in role_profiles.yaml.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
roleYesAgent role name (e.g. 'discovery', 'execution')
projectYesProject name

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Discloses that the tool does not read or modify session.md, describes return format (markdown string), and details error behavior (raises string if role not registered). Since no annotations are provided, the description carries full burden and does so thoroughly.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Description is compact but comprehensive: first sentence defines main action, second gives usage guideline, third explains valid role values, fourth describes return and error. Well-structured and front-loaded with key information.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given that an output schema exists and parameter coverage is 100%, the description still adds value by explaining return format, error handling, and usage context. It completely addresses the tool's behavior and constraints.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema already covers both parameters (100% coverage), but description adds critical context: role values come from role_profiles.yaml, provides examples, and notes error handling for unrecognized roles. This goes beyond schema descriptions.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool assembles and returns a full context bundle for a named agent role, with specific verb 'assembles and returns' and resource 'context bundle'. It explicitly distinguishes from get_session_context by stating when to use each.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Provides explicit when-to-use (deliberate mid-session role switches) and when-not-to-use (session start, alternative named). Also clarifies that it does not read or modify session.md, giving clear context for safe usage.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/desikai-lab/Marrow'

If you have feedback or need assistance with the MCP directory API, please join our Discord server