feat: initial Lam Agent extension (#1)
This commit was merged in pull request #1.
This commit is contained in:
@@ -0,0 +1,33 @@
|
||||
/** Tunable constants for Lam Agent. Anything a future contributor might want to change lives here. */
|
||||
|
||||
export const DEFAULT_HOST = "https://ollama.com";
|
||||
export const DEFAULT_MODEL = "gpt-oss:120b";
|
||||
|
||||
/** LocalStorage keys. The index is small; each session body gets its own key so saving one never rewrites the others. */
|
||||
export const STORAGE_INDEX_KEY = "lam.sessions.index";
|
||||
export const STORAGE_SESSION_PREFIX = "lam.session.";
|
||||
|
||||
/** How many times the model may call tools before Lam gives up and reports back. */
|
||||
export const MAX_TOOL_ITERATIONS = 5;
|
||||
|
||||
/** Oldest sessions past this count are evicted, along with their storage keys. */
|
||||
export const MAX_SESSIONS = 100;
|
||||
|
||||
/** Defence against a single runaway session bloating LocalStorage. */
|
||||
export const MAX_TURNS_PER_SESSION = 200;
|
||||
export const MAX_STORED_CHARS_PER_TURN = 20_000;
|
||||
|
||||
/** How much of a prompt becomes the session title in the session list. */
|
||||
export const TITLE_MAX_LENGTH = 60;
|
||||
|
||||
export const DEFAULT_SYSTEM_PROMPT = `You are Lam, a concise assistant built into the Vicinae launcher on the user's desktop.
|
||||
|
||||
- Lead with the answer, then add supporting detail. Do not pad with pleasantries.
|
||||
- You render inside a narrow launcher window: keep paragraphs short and prefer tight markdown lists. Avoid wide tables and large headings.
|
||||
- Call the tools you are given when they would make your answer more accurate. Anything time-sensitive, or after your training cutoff, should be checked with a tool rather than guessed.
|
||||
- Never invent tool output. If a tool fails, say so plainly and answer with what you already know.
|
||||
- When you are unsure, say what you are unsure about instead of hedging vaguely.`;
|
||||
|
||||
/** Extra instruction appended when the user has web tools enabled and the question looks time-sensitive. */
|
||||
export const RECENCY_HINT =
|
||||
"If the answer depends on current events, prices, versions, or releases, use web_search before answering.";
|
||||
Reference in New Issue
Block a user