@struktoai/mirage-core
Version:
A Unified Virtual Filesystem For AI Agents
27 lines • 1.89 kB
TypeScript
import type { Workspace } from '../workspace/workspace/workspace.ts';
/**
* The default system prompt: how the Mirage filesystem differs from a plain one.
*
* `buildSystemPrompt` starts from it; use it as the agent's instructions
* when no mount description is needed.
*/
export declare const MIRAGE_SYSTEM_PROMPT = "Your filesystem is powered by Mirage \u2014 a virtual filesystem that mounts cloud storage, local files, and in-memory data as a unified file tree.\n\nCapabilities beyond standard filesystem:\n- head -n 5 on data files returns the first 5 rows\n- grep works on structured text such as CSV and JSON, not just plain text\n- Pipes work: cat data.csv | grep error | sort | uniq | wc -l\n- head, tail, cut, wc, sort, uniq, tee, xargs are all available\n- Start a recursive grep or rg inside the mount you mean, not at /: a mount searches with its own index only when the search starts inside it\n\nYou can write Python code and execute it. The workspace is pre-configured with your data sources mounted at their respective paths.\n\nUse the shell tool for complex operations. Use read/write/edit for simple file operations.\n";
/**
* Options for `buildSystemPrompt`: which mounts to describe and what to append.
*
* Pass a `workspace` (and `sessionId`) whose mounts to describe, or
* `mountInfo` mapping a prefix to a description when there is no workspace,
* and `extraInstructions` to append.
*/
export interface BuildSystemPromptOptions {
workspace?: Workspace;
sessionId?: string | undefined;
mountInfo?: Record<string, string>;
extraInstructions?: string;
}
/**
* Returns `MIRAGE_SYSTEM_PROMPT` followed by a description of the mounted
* paths and any extra instructions, ready to use as an agent's system prompt.
*/
export declare function buildSystemPrompt(opts?: BuildSystemPromptOptions): Promise<string>;
//# sourceMappingURL=prompt.d.ts.map