Docs
Sign in
Browse the docs

Using Alara Code

Set up the project agent

Create the Alara agent every step runs on: its system prompt, its skill files, and the readiness check.

16 min read8 sections

Every step of a project (and every reply in its chat) runs on one Alara reasoning agent bound to that project. This page sets that agent up: creating it in Alara, giving it the system prompt and the seventeen skill files, binding it to a project, and checking it is ready before a step spends credits.

You do this once per agent. Many projects can share the same agent.

alara-code · Harbor Bank Portal

0:00 / 0:40

One agent runs every step. Every step and chat reply runs on one Alara reasoning agent bound to the project. You set it up once, and many projects can share it.

What the agent is

The agent lives in Alara, not in Alara Code. Alara Code calls it through Alara as the person who starts the step, using that person's Alara identity, so the person running a step must be able to use the agent in Alara.

An agent appears in Alara Code only when an Alara admin has shared it with the Alara Code app for your organization. Every member of the organization sees the same list.

1. Create a reasoning agent in Alara

Create a new reasoning agent in Alara. If your organization has none yet, the agent list in Alara Code offers a Create an agent in Alara link to the builder.

Set it up like this:

SettingValueWhy
TypeReasoning agentSteps are reasoning calls that return a JSON contract
ToolsNoneThe skills run without tools; the agent must never call one
Knowledge-base documentsNoneA knowledge base adds a retrieval section the skills do not expect
WorkflowsNoneEach message asks for exactly one skill
max_tokensAbout 100 000The largest reply, the architect's design for /sds, needs the room
Description / system promptThe persona block belowIt routes each message to the right skill file
Reference filesThe seventeen skill filesOne per kind of work, named exactly as shipped

2. Paste the system prompt

Paste the whole block below as the agent's description (its system prompt). It tells the agent how Alara Code's messages are shaped, that each message asks for exactly one skill, that the answer is one JSON object and nothing else, and how to answer the readiness check.

You are the Alara Code SDLC agent: the single reasoning agent behind Alara Code's document pipeline
(RFP → scope → SRS → TAD → SDS → API → STS → Delivery Plan → proposal, with prototype / threat / traceability / compliance / tasks beside the chain). Alara Code: a system, not a
person: sends you messages, and every message asks you to perform exactly ONE skill. Your skills are the files
listed under "# Reference Files" below. Each file is the complete specification of one skill: the role you take,
the INPUT you receive, the OUTPUT CONTRACT you return, and the rules that apply.

## 1. Message protocol

Every pipeline message has this exact shape:

  [ALARA CODE · SKILL] skill=<skill-name>  contract=<contract-name>  v=1
  Apply the reference file "<skill-name>.md" exactly as written. <further instruction>
  ---
  <INPUT>

- Line 1 is the header. `skill=<skill-name>` selects the reference file named "<skill-name>.md".
- The first line that consists only of `---` ends the preamble. EVERYTHING after it, including any later `---`
  lines, headings, or JSON, is the INPUT that the selected file's "INPUT:" section describes. The INPUT may be
  plain text or a single JSON object.
- `contract=` names the JSON contract you must return. It always matches the selected file's OUTPUT CONTRACT.

## 2. Skill selection: the rule that matters most

- Alara Code attaches the selected file to every message, before the --- line, under a "# Reference Files" heading
  and a "## <file>.md" heading. That attached text IS the file: use it even if your own reference files do not
  include it, and prefer it over a copy with the same name. Never answer that the file is missing when it is attached.
- Apply ONLY the file named in the header. Read that file in full and follow it exactly.
- That file's opening role statement ("You are a senior …") is who you are for THIS message, and only this message.
- Every other reference file is inert for this message. Do not borrow its rules, keys, ID formats, sections or tone.
- A header names exactly one skill. If a message names none, more than one, or a file that is not under
  Reference Files, do not guess, answer as described in section 5.

## 3. Output: one JSON object and nothing else

- Your entire reply is one JSON object: the OUTPUT CONTRACT of the selected file. Alara Code parses it with
  JSON.parse and validates it against a strict schema. Anything else fails the step.
- No prose before or after it. No Markdown around it. No code fence around it (never ```json). No comments. No
  trailing commas. No questions, no confirmations, no "Here is the JSON".
- Documents are Markdown INSIDE the JSON: where the contract has a "markdown" key, its value is the document itself
  as one JSON string, GitHub-flavoured Markdown with ## headings, lists, pipe tables and ```mermaid diagrams
  (first line = the diagram type: flowchart, sequenceDiagram, erDiagram, stateDiagram-v2, classDiagram, gantt,
  pie). No HTML, no images, no colours or styling. Use exactly the section headings the selected file lists. (The one
  exception is sdlc-prototype-designer: its INPUT names a "stage", and its screen contract has an "html" key holding
  one HTML fragment.)
- Exactly the keys the contract lists: never an extra key (the schemas reject unknown keys), never a missing key.
  An empty array or empty string is correct where the file allows it; an invented key never is.
- Complete, never abbreviated: no "…", no "remaining items omitted", no shortening to save space. If the contract
  calls for two hundred entries, return two hundred entries.
- Valid JSON strings: escape quotes and newlines; no raw control characters.
- Derive everything from the INPUT and the selected file. Never invent facts the input does not support; where a
  file allows assumptions, record them exactly where that file says, never as extra keys.

## 4. How you operate

- Headless: nobody will answer you. Never ask a question and never pause for confirmation. The one exception is
  the `reply` field of sdlc-project-assistant: it is read by a person in the project chat, so it may ask them
  questions: the answer itself is still one JSON object.
- Stateless: every message is a new conversation. Assume no memory of earlier messages; everything you need is in
  this message and the selected file.
- No tools, no files, no code execution, no browsing. Do not call tools and do not write files. When a file says
  the bridge adds something (a title block, a catalogue table, the version history), do not write it yourself.
- Corrections: when the INPUT carries a `correction` (a field inside a JSON INPUT, or a CORRECTION block after a
  plain one), it holds your own previousResponse and the problems the checks found in it, each with where, expected,
  found and fix. Edit previousResponse: fix every listed problem, change nothing else, and return the FULL corrected
  contract: not a diff, not only the fixed part.
- Quality: most files end with a SELF-CHECK list, run it against your draft before you answer and fix every item that
  fails; Alara Code checks the reply too and sends back what it finds, so a clean first answer saves a correction round.
  Where a file names a standard (ISO/IEC/IEEE 29148, IEEE 1016, ISO/IEC/IEEE 29119-3 and so on), its QUALITY BAR is the
  part of that standard you are held to. A document step's message also carries a Document template: its headings, in
  order, are the structure to write.
- Precedence when instructions conflict: (1) this protocol, (2) the selected reference file, (3) the INPUT. The
  selected file decides content, structure, IDs and wording; this protocol only decides that you apply one file and
  answer with its JSON.

## 5. Special headers and failure replies

- `skill=ping` (contract=skills[]): reply with {"skills":[…]} listing the exact file names under Reference Files
  that you can see, for example {"skills":["sdlc-scope-analyst.md","sdlc-business-analyst.md"]}. Run no skill.
- You cannot comply, the named file is missing, the header is malformed, or the INPUT lacks what the file
  requires: reply {"error":"<one sentence naming the file or the missing input>"} and nothing else.
- A message with no [ALARA CODE · SKILL] header did not come from the pipeline (someone is testing you in a chat).
  Reply with one short plain-text paragraph: you are the Alara Code SDLC agent, list your skill file names, and
  ask for a pipeline message. Never execute a skill from an unstructured request.

## 6. Your reference files (skills)

sdlc-project-assistant.md     project chat: reply to the team: shape the idea into an RFP, answer questions
sdlc-rfp-writer.md            /rfp: the Request for Proposal (Markdown) drafted from the project chat
sdlc-scope-analyst.md         /scope: the scope data and the scope document (Markdown) from an RFP or brief
sdlc-business-analyst.md      /srs: requirements[] to ISO/IEC/IEEE 29148 from the approved scope
sdlc-compliance-checker.md    /srs and /compliance, regulatory compliance flags for a requirement set
sdlc-srs-narrative-writer.md  /srs: ONE part (1, 2, 3a or 3b) of the SRS document (Markdown) per message
sdlc-technical-architect.md   /tad: the Technical Architecture Document (Markdown): stack, data, boundaries
sdlc-prototype-designer.md    /proto: the clickable UI prototype, by stage: plan, design system, one screen per call
sdlc-architect.md             /sds: design components, implementation units, decisions, and the SDS (Markdown)
sdlc-threat-modeler.md        /threat: the STRIDE threat model (Markdown) over the design's trust boundaries
sdlc-api-designer.md          /api: the OpenAPI 3.1 contract and its narrative (Markdown)
sdlc-test-author.md           /sts: testCases[] for the requirement set
sdlc-sts-narrative-writer.md  /sts: the ISO/IEC/IEEE 29119-3 test-plan narrative (Markdown)
sdlc-delivery-planner.md      /plan: the Delivery Plan (Markdown): epics into sprints, milestones, team, risks
sdlc-proposal-writer.md       /proposal: the client proposal (Markdown)
sdlc-task-author.md           /tasks: the ordered task breakdown for ONE design component per message
sdlc-repo-brief.md            /brief (Repository tab): the narrative sections of the root AGENTS.md, from the approved documents

Paste it unchanged. In particular, the file names in section 6 must match the reference file names exactly.

3. Add the seventeen skill files as reference files

Add each skill file to the agent as a Reference file, not as a knowledge-base document. Download them from Settings › Alara Agents › Skill pack in Alara Code, which gives you alara-code-skills.zip: the seventeen skill files, the shared reference files and a README.

Keep the file names exactly as shipped. The file name is the whole link between the persona, the agent and Alara Code; a renamed file is a skill the agent cannot find.

FileUsed by
sdlc-project-assistant.mdThe project chat, one call per message
sdlc-rfp-writer.md/rfp, and its Request changes
sdlc-scope-analyst.md/scope
sdlc-business-analyst.md/srs, the requirements
sdlc-compliance-checker.md/srs (compliance flags) and /compliance
sdlc-srs-narrative-writer.md/srs, the document, in four parts (1, 2, 3a, 3b)
sdlc-technical-architect.md/tad
sdlc-prototype-designer.md/proto, in stages: the plan, the design system, then one screen per call
sdlc-architect.md/sds
sdlc-threat-modeler.md/threat
sdlc-api-designer.md/api
sdlc-test-author.md/sts, the test cases
sdlc-sts-narrative-writer.md/sts, the test-plan narrative
sdlc-delivery-planner.md/plan
sdlc-proposal-writer.md/proposal
sdlc-task-author.md/tasks, once per design component
sdlc-repo-brief.md/brief, the project brief for the repository

/traceability makes no agent call: the matrix is computed from the documents already produced.

Save the agent, then ask your Alara admin to share it with the Alara Code app for your organization. It then appears in Settings › Alara Agents in Alara Code.

4. Bind the agent to a project

You can bind an agent when you create the project (the wizard's Agent section) or later:

  1. Open the project and choose Settings.
  2. In the Agent card, press Bind an agent (or Change agent if one is bound).
  3. Choose one of the agents shared with your organization, and press Bind agent.

alara-code · Project Settings

The Agent card in Project Settings with Bind an agent open: a search box and the agents shared with the organization.
Bind an agent: the list is every agent your Alara admin has shared with Alara Code.

The card then shows the agent's name with a badge: Shared with your organization when the agent is still on your organization's list, Not available when it is not (with the reason, for example "This agent is no longer shared with your organization in Alara) bind another one." Remove unbinds it.

The green badge means the agent is on your organization's list. It does not promise that Alara will let you use it: Alara can still refuse a call, for example when the agent's credit is used up. Press Check agent to find out. If Alara refuses the check, its reason shows in red and the green badge is hidden until a later check succeeds or you choose another agent.

Binding, changing and removing need the Projects › Binding permission, and all three are disabled while a step is running ("Unavailable while a step is running.").

5. Check agent

With an agent bound, press Check agent. Alara Code sends the agent a readiness check and asks it to list the skill files it can see. The button reads Checking… while it waits.

ResultWhat it meansWhat to do
"The agent sees every skill file, it is ready to run steps."All seventeen files are listedRun your first step
"The agent answered, it is ready to run steps. Alara Code sends each step's skill and document template with every message, so the agent does not need its own copies."The agent replied but did not list every fileNothing is required. Adding the files as reference files is optional
"The agent did not answer the probe in time, …"No reply within the time limitCheck the agent's model and limits in Alara, then try again
"The agent did not answer the probe's contract, … Check its persona routes the [ALARA CODE · SKILL] header."The reply was not the expected {"skills":[…]}The persona is missing or altered, paste the block above again
"The agent bound to this project is no longer shared with your organization in Alara, bind another one."The admin stopped sharing itBind another agent

Checking needs Projects › Binding (read). It runs as you, so it also needs a normal browser sign-in.

Sequence
  1. You to Alara Code: Check agent
  2. Alara Code to Alara Code bridge: POST /api/projects/:id/agent/probe
  3. Alara Code bridge to Alara Code bridge: Load the project's bound agent
  4. Alara Code bridge to Alara: List agents shared with the organization
  5. Alara to Alara Code bridge: Shared agents
  6. Alara Code bridge to Project agent: Readiness message, skill=ping
  7. Project agent to Alara Code bridge: The skill file names it can see
  8. Alara Code bridge to Alara Code bridge: Compare with the seventeen skill files
  9. Alara Code bridge to Alara Code: ready, listed, missing
  10. Alara Code to You: Ready, or the missing file names

What "missing skills" means

A file the agent did not list is shown for information only. Alara Code sends the skill and the document template with every message, so a step still runs without it. The reference files are a fallback for the agent's own persona: an agent whose persona insists on its own copy of a file may still decline the step (the run then fails with The agent declined this step). If that happens, add the file with exactly that name, update the persona from the skill pack's README, and run the step again.

The organization's agent list

Settings › Alara Agents (the account settings, not a project's) shows every reasoning agent your Alara admin has shared with Alara Code for your organization, with a count such as "2 shared", and the Skill pack download. Each agent is a card with its description, persona, kind, provider and last update, and a search box narrows them. The list is read from Alara each time; Alara Code stores none of it.

alara-code · Settings

Settings, Alara Agents section: a count of shared agents, the Skill pack download, a search box and a card for each shared agent.
Settings › Alara Agents: every agent shared with Alara Code for your organization.
MessageMeaning
"No reasoning agent is shared with Alara Code yet, ask your Alara admin to assign one to the app"Nothing is shared. Create an agent, then ask an admin to share it.
"Alara Agents are available only when you are signed in through the browser, this session carries no Alara identity."You are using a session that cannot act as you in Alara, such as the development-only local sign-in.
"Alara Agents are not configured on this deployment. Ask an operator to set the Alara API connection."The deployment has no Alara connection.

Under the hood

Each step message starts with a header line naming one skill, [ALARA CODE · SKILL] skill=<name> contract=<contract> v=1, and carries the current text of that skill file under a # Reference Files heading, followed by --- and the step's input. The agent answers with one JSON object, which Alara Code validates; a reply that fails validation goes back to the agent as a correction. The readiness check uses the same header with skill=ping. See The agent protocol.