Anna App Backend Tool Executa Pre-Release Inspection Guide

Anna App Backend Tool Executa Pre-Release Inspection Guide

Purpose: Provide this document along with an Anna App project directory to an AI Agent to verify whether the project can properly install, start, describe, and invoke the backend Tool Executa.

Scope: This guide applies to Anna Apps with various directory structures, languages, tool counts, and distribution methods. Placeholders written as <...> must be replaced with the actual values of the project under inspection. This guide does not rely on any specific sample repository, nor does it require tools to use Go, Node, or any particular build method.

To the Agent Executing the Inspection

Please read this document, then inspect the user-provided App project. First discover the project’s actual directories, configurations, tools, CLI versions, and release targets before executing subsequent checks. Do not assume the project has fixed bundle/, executas/, tool names, or method names.

The default task is to read, build, test, and output a report—not to release the App, modify remote authorizations, upload artifacts, or install cloud versions. Only modify project files when explicitly requested by the user for fixes. When testing requires credentials or external services, use safe test data; do not write credentials, tokens, environment variables, or full identity caches into the report.

The final report must itemize Status, Evidence, Issues, Impact, and Next Steps for each check. Unexecuted checks must not be marked as passed.

1. Evaluation Criteria

1.1 Status

Status Condition for Use
PASS Executed; evidence conforms to the Anna CLI, schemas, and runtime rules actually used by the current project.
FAIL Evidence indicates configuration, protocol, artifacts, or actual execution do not meet requirements.
WARN Backward-compatible behavior, recommended practices, version discrepancies, or linter/tool false positives; explain actual impact.
BLOCKED Missing target platform, dependency, authorization, credential, or artifact; evaluation cannot be completed.
N/A Truly not applicable; explain the reason.

1.2 Priority

  • P0: Tool cannot install, start, or return a valid describe.
  • P1: Tool starts, but has issues with methods, parameters, permissions, frontend linkage, or release artifacts.
  • P2: Maintainability, readability, recommended practices, or compatibility warnings that do not affect the current invocation.

After a step fails, continue checking items that do not depend on it. Items depending on a failed step should be marked BLOCKED and point to the original root cause, avoiding counting the same issue multiple times.

2. Five-Minute Blocker Checks

Complete the following quick checks before proceeding to the full audit. If any P0 item fails, the final conclusion cannot be “ready for release.”

Check Must Confirm Fact
Tool Directory Every bundled_executas[ref_name].path in app.json exists, and the directory genuinely contains the corresponding tool configuration.
App Dependencies required_executas / optional_executas references in the root manifest.json resolve to these tools.
UI Entrypoint ui.bundle.entry exists relative to the final UI bundle root directory, and the page loads.
Frontend Tool ACL ui.host_api.tools permits the frontend to invoke the tools it actually depends on.
Distribution Profile The active executa.json profile has an installable local package, binary archive, or URL.
Binary Entrypoint manifest.json at the archive root and runtime.binary.entrypoint point to an actual executable inside the archive.
describe In the JSON-RPC describe response of the actual release binary, result is a bare tool manifest object.
Method Contract tools[].name, parameter types, and the methods actually handled by the backend are consistent.
stdio stdout contains only single-line JSON-RPC messages; after responding, the process continues reading stdin; exits cleanly on EOF.
Real Artifact Launched from the final archive rather than just running from the source path, successfully completing at least one describe and one safe invocation.

3. S0: Discover Project and Inspection Scope

3.1 Locate Actual App

  1. Confirm the directory requested by the user. If a repository contains multiple Apps, locate each App’s app.json, root manifest.json, and release scripts separately; do not mix them up.
  2. Read applicable AGENTS.md, README, package.json, build scripts, and startup scripts.
  3. Record Git branch, commit, and workspace changes; for non-Git projects, record file versions or modification times.
  4. Record the actual version of Anna CLI, Node, Python, Go, or other runtime environments used. Do not replace the project’s pinned CLI version with another version.
  5. Record override parameters for release commands, such as --manifest, --bundle-dir, --profile, and --executa-id. Effective values after CLI overrides may differ from default configurations.
  6. Record target cloud platforms and CPU architectures. Report BLOCKED if the target is unknown; do not treat the development machine’s platform as the cloud platform.

You may first use the following commands to discover files, then inspect files based on the actual project:

pwd
git status --short
git rev-parse HEAD
rg --files --hidden -g '!node_modules' -g '!.git' -g '!dist' -g '!vendor' -g '!coverage'

3.2 Build Tool Inventory

Record at least the following for each tool:

Field Content
Reference Name Key in app.json
Tool Directory Resolved absolute path
App Dependency bundled:<ref_name> or actual tool ID
Local Startup type, command, working directory
Active Profile local, binary, npm, uv, etc.
Version Versions in executa.json, tool manifest, and artifacts
Methods Actual list of tools[].name
Target Platforms Archive or URL for each platform
Capabilities & Credentials Declarations in App, tool, and invocation contexts

4. S1: Verify Configuration Chain

4.1 JSON Files

Inspect the following discovered files; do not copy example paths as hardcoded rules:

  • App’s app.json;
  • App root manifest.json;
  • Each tool’s executa.json;
  • Tool protocol manifest prepared for upload (if the release workflow uses external files);
  • Distribution manifest.json at the root of each binary archive.

Every file must be a UTF-8 JSON object. Check for parse errors, BOMs, trailing commas, top-level arrays or strings, and duplicate keys. Duplicate keys should be reported as WARN with an explanation of which value the actual parser adopts; do not claim without evidence that all CLIs will reject duplicate keys.

If tool descriptions are constructed directly in code, do not mark protocol failure merely because an independent manifest.json is missing. Continue checking whether the actual describe returned by the program and the release workflow have an equivalent description source.

4.2 app.json and bundled_executas

Verify:

  1. app.json is a valid object, and slug, version, and metadata conform to the schema of the project’s actual CLI.
  2. bundled_executas is an object where keys are App internal reference names, and values contain at least a non-empty path.
  3. path resolves relative to the App root directory, the directory genuinely exists, and it is not a UI bundle or another tool directory.
  4. executa.json inside that directory corresponds to this reference name and tool version.
  5. Every bundled:<ref_name> in the root manifest resolves; do not substitute string prefix similarity for an actual mapping.
  6. Keys used in frontend mappings match reference names exactly, respecting case, hyphens, and underscores.

Reference names, server-generated tool_ids, top-level name in tool manifests, and tools[].name are distinct concepts. Do not require them to use the same string.

4.3 Root manifest.json

Check field locations according to the project’s actual schema. Common fields include:

  • schema;
  • required_executas, optional_executas;
  • ui.bundle, ui.views, ui.host_api;
  • App top-level host_capabilities, storage, permissions;
  • dev, tags, and prompt fields.

Focus on:

  1. Required tool references in required_executas match app.json, and optional_executas does not duplicate them.
  2. ui.bundle.entry is a path relative to the final UI bundle root directory; do not duplicate bundle/ into entry.
  3. The entry file genuinely exists in the final release bundle.
  4. ui.host_api.tools matches the scope of frontend invocations; a UI that does not invoke tools should not declare tool permissions out of thin air.
  5. permissions, host_capabilities, and ui.host_api must be checked against the current schema; do not apply legacy field placements to newer projects.
  6. Dependencies, views, and capabilities in the App manifest match actual code usage.

4.4 executa.json and Distribution Profiles

For each tool, identify the profile actually adopted by the release command. Priority is typically an explicit --profile on the release command, followed by active in the configuration, and finally the sole profile; defer to the actual behavior of the project’s CLI.

Verify:

  1. Local type, command, and working directory can start the tool. command should be a list of argv strings unless the project explicitly relies on shell parsing.
  2. The type of the active profile matches the release method; development local is not equivalent to a cloud-installable release package.
  3. A binary profile chooses one actually used between binary_artifacts and binary_urls; do not arbitrarily require all projects to provide both.
  4. Path, URL, format, entrypoint, version, size, and hash for each target platform can be resolved.
  5. The relationship between tool manifest, executa.json, and artifact versions is clear. App versions and tool versions can evolve independently; do not force them to be equal.
  6. supports_protocol, capabilities, and credential declarations align with the tool’s actual usage.

4.5 Differentiate the Three Types of Bundles and Manifests

Object Purpose Typical Location
App UI Bundle Pages, static assets, and ui.bundle.entry App’s final UI bundle directory
Bundled Executa Directory executa.json, tool description source, and build inputs Directory pointed to by bundled_executas[*].path
Binary Archive Cloud-installed program, dependencies, and archive root manifest Compressed archive pointed to by binary_artifacts or URL
App Runtime Manifest App schema, UI, dependencies, and frontend ACL App root manifest.json
Tool Protocol Manifest version, tools, parameters, capabilities, and credentials describe.result or tool description file
Archive Distribution Manifest Installation entrypoint, permissions, runtime, and archive metadata Binary archive root manifest.json

When files are all named manifest.json, they must still be evaluated separately according to their location and purpose.

5. S2: Verify Tool Protocol Manifest and describe

5.1 Find Description Sources

Record two sources:

  1. Tool description prepared for upload or synchronization by the release workflow;
  2. describe actually returned by the program after installation.

Descriptions may originate from standalone files, code constants, or build-time embedded assets. It must be available with the final artifact. When using host capabilities, returning capabilities from the local runtime alone is insufficient; confirm that the release workflow synchronizes the correct description.

5.2 Outer Format of describe

Tool receives:

{"jsonrpc":"2.0","id":"audit-describe","method":"describe"}

The core shape of a successful response is:

{
  "jsonrpc": "2.0",
  "id": "audit-describe",
  "result": {
    "version": "<semver>",
    "description": "<tool description>",
    "tools": [
      {
        "name": "<method name>",
        "description": "<method description>",
        "parameters": []
      }
    ]
  }
}

Must confirm:

  • Outer jsonrpc is the string "2.0";
  • Response id matches the request ID;
  • result is directly the tool manifest object;
  • result is not a string, nor does it have extra wrappers like manifest, success, or data;
  • version, description, and tools have correct types;
  • tools contains at least the methods actually provided by the project;
  • Top-level metadata such as name and display_name are handled according to actual CLI/runtime versions. Some current release examples omit top-level name; do not treat it as a universal hard requirement without version evidence.

None of the following response shapes can be accepted as a correct describe:

{"jsonrpc":"2.0","id":1,"result":{"manifest":{"version":"0.1.0"}}}
{"jsonrpc":"2.0","id":1,"result":{"success":true,"data":{"version":"0.1.0"}}}
{"jsonrpc":"2.0","id":1,"result":"{\"version\":\"0.1.0\"}"}

5.3 Methods and Parameters

Compare tools[] one-by-one against backend registries, dispatch branches, or test cases:

  1. tools[].name is unique within the same tool, and matches params.tool in invoke and the frontend method.
  2. description is a string explaining the method’s purpose.
  3. parameters is a list; can be [] when there are no parameters.
  4. name, type, description, required, default, enum, and array item declarations for each parameter match the code.
  5. Parameter types use those currently supported by Anna: string, integer, number, boolean, array, object. Do not insert Go, Python, or TypeScript type names directly.
  6. Array items_type or items uses syntax supported by the project’s current CLI/runtime, and validates actual elements.
  7. integer does not accept booleans or floats; test number, boolean, empty strings, empty arrays, and empty objects according to business contracts.
  8. timeout uses the time unit specified by the protocol; do not mix seconds, milliseconds, and frontend timeoutMs.

Parameter descriptions define inputs, not outputs automatically. Business data returned by tools does not need to include identically named fields.

5.4 Capabilities, Credentials, and Storage

Establish the following cross-reference table:

Source Items to Verify
App Manifest Top-level capabilities, ui.host_api, tool invocation ACL, storage, and upload permissions
Tool Manifest host_capabilities, credentials, storage/upload/reverse RPC declarations
Executa Profile Capability and credential configurations synchronized during release
Code Host, storage, sampling, web, or other reverse RPCs actually invoked

Declarations must match actual usage. When a tool uses aps.files, host.upload, sampling, or other host capabilities, descriptions, App authorization, user authorization, and runtime negotiation must all be checked simultaneously. If a tool uses no credentials or capabilities, report N/A; do not fail it simply because optional declaration files are absent.

6. S3: Actually Test stdio and Lifecycle

6.1 Launch the Correct Process

Prioritize testing the final release profile and the actual binary. Source commands only prove the development path works, not that the cloud archive is installable.

Launch the process using the project’s real argv and working directory. If the project already has a check, test, describe, or protocol runner, read the script before running it, and record the version, command, exit code, and key output.

If the project lacks an existing runner, the Agent may create a short test script in a temporary directory. This program must:

  1. Write a single line of JSON via stdin and flush immediately;
  2. Read a complete line from stdout and parse strictly as UTF-8 JSON;
  3. Validate the JSON-RPC envelope, response ID, and exclusivity between result and error;
  4. Set a timeout for every request;
  5. Close stdin and wait for clean termination;
  6. Avoid committing temporary scripts or credential-bearing output to the repository.

6.2 stdout, Framing, and Sizing

Inspect the actual byte stream:

  • stdout must write only JSON-RPC responses; logs, debug information, and progress go to stderr;
  • Each message is UTF-8, single-line JSON, terminated with \n, and promptly flushed;
  • The process continues reading stdin after returning a response;
  • Exits cleanly when stdin is closed; must not crash or hang on EOF;
  • Check message size against the target protocol version. The current staging protocol page lists a soft limit of approximately 512 KiB for MAX_STDIO_MESSAGE_BYTES and a hard limit of 2 MiB for MAX_READLINE_BYTES; do not assume 16 MiB is a universal rule across all versions;
  • Large results must use platform-supported file or upload transfers, and be tested against the actual host; do not assume the frontend can display it just because stdio can read it.

6.3 initialize and describe

If the runtime supports negotiation, send initialize before describe. Record:

  • Negotiated protocolVersion;
  • Structure and capabilities of initialize.result;
  • Whether it falls back to a compatible version due to -32601, timeout, or other protocol errors;
  • Actual spelling of server_info or serverInfo and its version basis. Both spellings exist in current documentation and implementations; checkers must not enforce one without a version baseline;
  • Duration of describe and whether the initial cold start uses a longer budget.

If an ordinary tool does not support initialize, record a compatibility WARN and continue checking describe. For tools depending on v2 reverse RPCs, if negotiation cannot complete, related capabilities cannot be marked as passed.

Send describe at least twice with valid IDs of different types (e.g., string and integer) to confirm IDs correspond as-is and the same process continues running.

6.4 invoke and Error Recovery

The standard request shape is:

{
  "jsonrpc": "2.0",
  "id": "invoke-1",
  "method": "invoke",
  "params": {
    "tool": "<tools[].name>",
    "arguments": {},
    "context": {}
  }
}

Verify:

  1. params.tool is the method name, not the server tool_id.
  2. arguments is a JSON object; credentials and host context reside in the sibling context.
  3. JSON-RPC errors use error.code and error.message; common parse, invalid request, unknown method, invalid params, and internal errors are validated against the target protocol version.
  4. Business failures use the tool’s agreed success: false structure; do not disguise business failures as success.
  5. The data type in a successful response is determined by that method’s business contract. Protocol checks only validate valid JSON and the agreed envelope; do not force data to be an object across all tools.
  6. For each safe method, test at least once with valid input, missing required parameters, invalid types, and one business failure branch; supplement with empty values, defaults, and boundary values per method contract.
  7. Send describe or a safe invocation again after every protocol or business error to confirm the process did not crash.

6.5 Minimum Request Sequence

Where project capabilities and business logic permit, use the following sequence to collect evidence:

Start process
→ initialize (if supported)
→ describe
→ describe (different ID)
→ one safe invoke
→ one expected error
→ describe (confirm recovery)
→ close stdin
→ wait for process to terminate with exit code 0

Tools requiring credentials, uploads, sampling, storage, or external networks must use a host runner suitable for those capabilities; simplified scripts lacking reverse RPC support cannot be used to declare capabilities as passed.

7. S4: Inspect Binaries and Release Artifacts

7.1 Platforms and Archives

Record for each target platform:

  • Platform key, OS, and CPU architecture;
  • Archive path or URL;
  • Archive format, size, SHA-256, and build version;
  • Dynamic libraries, interpreters, auxiliary files, and data files required by the target platform.

Platform keys, direct upload allow-lists, and URL distribution lists may vary across CLI versions. First record the actual CLI/schema, then check against that version; do not treat a specific CLI version’s list as a permanent specification.

7.2 Archive Root Manifest and Entrypoint

Extract the archive intended for release into a temporary directory and verify:

  1. The root directory contains the distribution manifest.json required by the platform;
  2. runtime.binary.entrypoint is a path relative to the install root, and the file genuinely exists;
  3. Unix entrypoints have execute permissions; Windows entrypoints have correct extensions and paths;
  4. manifest, executa.json, and actual files inside the archive have no conflicts in entrypoints, versions, or platforms;
  5. The archive does not depend on absolute paths from the development machine, unbundled source directories, or locally installed packages;
  6. Launch the entrypoint from the extracted directory, repeating S3’s describe and safe invoke tests;
  7. Tool descriptions returned by the archived binary remain consistent with those prepared for upload in methods, parameters, versions, capabilities, and credentials.

A missing archive file is a release input FAIL; an unknown target platform or inability to verify on the target system is BLOCKED.

8. S5: Verify Frontend Invocations

8.1 UI Bundle

Confirm ui.bundle.entry exists in the final release bundle, and that the page loads required scripts and assets. Check whether build scripts delete CLI-generated tool ID mappings, manifests, or other runtime files.

8.2 Tool IDs and Invocations

  1. The page loads CLI- or platform-generated tool ID mappings prior to invocation.
  2. Mapping keys match bundled Executa reference names in app.json.
  3. The frontend uses the runtime real tool_id; do not write local reference names as server IDs.
  4. method matches describe.tools[].name, and argument structures conform to parameters.
  5. Successful results, business failures, RPC errors, timeouts, and uninstalled tools all have comprehensible UI behaviors.
  6. All tools invoked by the frontend are permitted by ui.host_api.tools; unused permissions cannot be used as justification for passing.

9. S6: Run CLI Validation When Necessary

Inspect the project’s package manager, dependencies, and existing scripts first. Do not assume node_modules exists, nor automatically install or switch CLI versions just to clear failures.

If the project provides strict validation, run its actual command and record:

<project's own validation command>

CLI schema validation and frontend static scanning cannot replace:

  • Actual binary installation;
  • Actual describe communication;
  • Sustained stdio and error recovery;
  • Archive execution on target platforms;
  • Capability authorization and frontend invocation.

If the linter reports suspected typos, approximate fields, or version compatibility issues, refer back to configurations and runtime evidence. Report linter/tool false positives as WARN; do not casually modify business configurations just to make commands pass green.

10. Report Format

10.1 Environment and Scope

Project Root Directory: <absolute path>
Inspection Time: <UTC timestamp>
Git Commit: <commit or N/A>
Anna CLI / Schema: <actual version>
Target Platform: <platform, architecture, or BLOCKED>
Tool Count: <number>
Release Executed: No

10.2 Evidence Table

ID Check Item Status Priority Evidence Issues or Boundaries
C-01 App Tool References PASS/FAIL/WARN/BLOCKED/N/A P0/P1/P2 Files, commands, output, or response summary <details>
C-02 App Manifest & UI Bundle … … … …
C-03 Executa Profile … … … …
C-04 describe … … … …
C-05 stdio Lifecycle … … … …
C-06 Binary Archive … … … …
C-07 Capabilities & Credentials … … … …
C-08 Frontend Invocation … … … …

Evidence should include actual file paths, line numbers, commands, exit codes, platforms, response summaries, and versions. Do not include full credentials or environment variable values in the report.

10.3 Final Conclusion

Conclude by answering each of the following:

  1. Are there any P0 or P1 FAIL items?
  2. Are there any BLOCKED items causing cloud installation or authorization to remain unverified?
  3. Did the final binary pass describe, safe invoke, error recovery, and EOF tests?
  4. Do App references, tool descriptions, release profiles, archive entrypoints, and frontend invocations all point to the same set of versions?
  5. What items must be modified or supplemented with evidence before release?

Only when all applicable P0/P1 checks pass, no unexplained BLOCKED items remain, and final release artifacts have completed runtime verification can the conclusion “ready for release” be granted.

11. Versions and Official References

Official specifications may update alongside Anna CLI, schemas, and cloud runtimes. The report must always record actual versions; when discrepancies arise among documentation, CLI, and runtimes, retain actual responses and command outputs, and mark differences as WARN or BLOCKED rather than silently adopting legacy rules.