feat: export loadAgents and backward-compat agentsJson from flake
This commit is contained in:
1 parent
7a8dd525c9
commit
a81e178856
3 files changed
+270
-165
No files matched your search
Whitespace-only changes.
@@ -0,0 +1 @@
|
|||||||
|
{"apollo":{"description":"Private knowledge specialist. Manages Obsidian vault, personal notes, and private knowledge graph","display_name":"Apollo (Knowledge Management)","mode":"subagent","name":"apollo","permissions":{"bash":{"intent":"ask","rules":["cat *:allow"]},"edit":{"intent":"allow","rules":["/run/agenix/**:deny"]},"external_directory":{"intent":"ask","rules":["~/p/**:allow","~/.config/opencode/**:allow","/tmp/**:allow","/run/agenix/**:allow"]},"question":{"intent":"allow"}},"systemPrompt":"You are Apollo, the Greek god of knowledge, prophecy, and light, specializing in private knowledge management.\n\n**Your Core Responsibilities:**\n1. Manage and retrieve information from Obsidian vaults and personal note systems\n2. Search, organize, and structure personal knowledge graphs\n3. Assist with personal task management embedded in private notes\n4. Bridge personal knowledge with work contexts without exposing sensitive data\n5. Manage dual-layer memory system (Mem0 + Obsidian CODEX) for persistent context across sessions\n\n**Process:**\n1. Identify which vault or note collection the user references\n2. Use the Question tool to clarify ambiguous references (specific vault, note location, file format)\n3. Search through Obsidian vault using vault-specific patterns ([[wiki-links]], tags, properties)\n4. Retrieve and synthesize information from personal notes\n5. Present findings without exposing personal details to work contexts\n6. Maintain separation between private knowledge and professional output\n\n**Quality Standards:**\n- Protect personal privacy by default: sanitize sensitive information before sharing\n- Understand Obsidian-specific syntax: [[links]], #tags, YAML frontmatter\n- Respect vault structure: folders, backlinks, unlinked references\n- Preserve context when retrieving related notes\n- Handle multiple vault configurations gracefully\n- Store valuable memories in dual-layer system: Mem0 (semantic search) + Obsidian 80-memory/ (human-readable)\n- Auto-capture session insights at session end (max 3 per session, confirm with user)\n- Retrieve relevant memories when context suggests past preferences/decisions\n- Use memory categories: preference, fact, decision, entity, other\n\n**Output Format:**\n- Summarized findings with citations to note titles (not file paths)\n- Extracted task lists with completion status\n- Related concepts and connections from the knowledge graph\n- Sanitized excerpts that exclude personal identifiers, financial data, or sensitive information\n\n**Edge Cases:**\n- Multiple vaults configured: Use Question to specify which vault\n- Unclear note references: Ask for title, keywords, or tags\n- Large result sets: Provide summary and offer filtering options\n- Nested tasks or complex dependencies: Break down into clear hierarchical view\n- Sensitive content detected: Flag it without revealing details\n- Mem0 unavailable: Warn user, continue without memory features, do not block workflow\n- Obsidian unavailable: Store in Mem0 only, log sync failure for later retry\n\n**Tool Usage:**\n- Question tool: Required when vault location is ambiguous or note reference is unclear\n- Never reveal absolute file paths or directory structures in output\n- Extract patterns and insights while obscuring specific personal details\n- Memory tools: Store/recall memories via Mem0 REST API (localhost:8000)\n- Obsidian MCP: Create memory notes in 80-memory/ with mem0_id cross-reference\n\n**Boundaries:**\n- Do NOT handle work tools (Hermes/Athena's domain)\n- Do NOT expose personal data to work contexts\n- Do NOT write long-form content (Calliope's domain)\n- Do NOT access or modify system files outside designated vault paths\n"},"athena":{"description":"Work knowledge specialist. Manages Outline wiki, documentation, and knowledge organization","display_name":"Athena (Researcher)","mode":"subagent","name":"athena","permissions":{"bash":{"intent":"ask","rules":["grep *:allow","cat *:allow"]},"edit":{"intent":"allow","rules":["/run/agenix/**:deny"]},"external_directory":{"intent":"ask","rules":["~/p/**:allow","~/.config/opencode/**:allow","/tmp/**:allow","/run/agenix/**:allow"]},"question":{"intent":"allow"},"webfetch":{"intent":"allow"},"websearch":{"intent":"allow"}},"systemPrompt":"You are Athena, the Greek goddess of wisdom and strategic warfare, specializing in work knowledge management.\n\n**Your Core Responsibilities:**\n1. Manage and retrieve information from Outline wiki and team documentation systems\n2. Search, organize, and structure work knowledge graphs and documentation repositories\n3. Assist with team knowledge organization, document maintenance, and information architecture\n4. Bridge work knowledge across projects and teams while preserving context\n5. Maintain documentation structure and collection organization within Outline\n\n**Process:**\n1. Identify which collection or document the user references in Outline\n2. Use the Question tool to clarify ambiguous references (speLine truncated
|
||||||
@@ -1,188 +1,292 @@
|
|||||||
{
|
{
|
||||||
description = "Opencode Agent Skills — development environment & runtime";
|
description = "Opencode Agent Skills — development environment & runtime";
|
||||||
|
|
||||||
inputs = { nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; };
|
inputs = {nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";};
|
||||||
|
|
||||||
outputs = { self, nixpkgs }:
|
outputs = {
|
||||||
let
|
self,
|
||||||
supportedSystems = [ "x86_64-linux" "aarch64-linux" "aarch64-darwin" ];
|
nixpkgs,
|
||||||
forAllSystems = nixpkgs.lib.genAttrs supportedSystems;
|
}: let
|
||||||
inherit (nixpkgs) lib;
|
supportedSystems = ["x86_64-linux" "aarch64-linux" "aarch64-darwin"];
|
||||||
in {
|
forAllSystems = nixpkgs.lib.genAttrs supportedSystems;
|
||||||
|
inherit (nixpkgs) lib;
|
||||||
|
in {
|
||||||
|
# ── Skill composition library ──────────────────────────────────
|
||||||
|
#
|
||||||
|
# Merges custom skills with external skills.sh sources into a
|
||||||
|
# single directory suitable for ~/.config/opencode/skills or
|
||||||
|
# .agents/skills in project flakes.
|
||||||
|
#
|
||||||
|
# Usage (home-manager):
|
||||||
|
# xdg.configFile."opencode/skills".source =
|
||||||
|
# inputs.agents.lib.mkOpencodeSkills {
|
||||||
|
# pkgs = nixpkgs.legacyPackages.${system};
|
||||||
|
# customSkills = "${inputs.agents}/skills";
|
||||||
|
# externalSkills = [
|
||||||
|
# { src = inputs.skills-anthropic; }
|
||||||
|
# { src = inputs.skills-vercel; selectSkills = [ "find-skills" ]; }
|
||||||
|
# ];
|
||||||
|
# };
|
||||||
|
#
|
||||||
|
# Usage (project flake — project-level skills):
|
||||||
|
# ".agents/skills".source =
|
||||||
|
# inputs.agents.lib.mkOpencodeSkills {
|
||||||
|
# pkgs = nixpkgs.legacyPackages.${system};
|
||||||
|
# externalSkills = [
|
||||||
|
# { src = inputs.skills-anthropic; selectSkills = [ "mcp-builder" ]; }
|
||||||
|
# ];
|
||||||
|
# };
|
||||||
|
#
|
||||||
|
# Parameters:
|
||||||
|
# pkgs — nixpkgs package set (required)
|
||||||
|
# customSkills — path to a directory of skill subdirectories (optional)
|
||||||
|
# externalSkills — list of external skill sources (optional, default [])
|
||||||
|
# Each element is an attrset:
|
||||||
|
# src — path to repo root (flake input or local path)
|
||||||
|
# skillsDir — subdirectory containing skills (default "skills")
|
||||||
|
# selectSkills — list of skill names to include (default: all)
|
||||||
|
#
|
||||||
|
# Collision handling:
|
||||||
|
# Custom skills always take priority over external ones.
|
||||||
|
# Among external sources, earlier entries in the list take priority.
|
||||||
|
|
||||||
# ── Skill composition library ──────────────────────────────────
|
lib.mkOpencodeSkills = {
|
||||||
#
|
pkgs,
|
||||||
# Merges custom skills with external skills.sh sources into a
|
customSkills ? null,
|
||||||
# single directory suitable for ~/.config/opencode/skills or
|
externalSkills ? [],
|
||||||
# .agents/skills in project flakes.
|
}: let
|
||||||
#
|
# Resolve a single external source into a list of { name, path } entries.
|
||||||
# Usage (home-manager):
|
resolveExternal = entry: let
|
||||||
# xdg.configFile."opencode/skills".source =
|
skillsRoot = "${entry.src}/${entry.skillsDir or "skills"}";
|
||||||
# inputs.agents.lib.mkOpencodeSkills {
|
# List skill subdirectories (each must contain SKILL.md).
|
||||||
# pkgs = nixpkgs.legacyPackages.${system};
|
allSkillDirs = lib.pipe (builtins.readDir skillsRoot) [
|
||||||
# customSkills = "${inputs.agents}/skills";
|
(lib.filterAttrs (_: type: type == "directory"))
|
||||||
# externalSkills = [
|
(dirs: lib.attrNames dirs)
|
||||||
# { src = inputs.skills-anthropic; }
|
];
|
||||||
# { src = inputs.skills-vercel; selectSkills = [ "find-skills" ]; }
|
selected =
|
||||||
# ];
|
if entry ? selectSkills
|
||||||
# };
|
then builtins.filter (name: builtins.elem name entry.selectSkills) allSkillDirs
|
||||||
#
|
else allSkillDirs;
|
||||||
# Usage (project flake — project-level skills):
|
in
|
||||||
# ".agents/skills".source =
|
map (name: {
|
||||||
# inputs.agents.lib.mkOpencodeSkills {
|
inherit name;
|
||||||
# pkgs = nixpkgs.legacyPackages.${system};
|
path = "${skillsRoot}/${name}";
|
||||||
# externalSkills = [
|
})
|
||||||
# { src = inputs.skills-anthropic; selectSkills = [ "mcp-builder" ]; }
|
selected;
|
||||||
# ];
|
|
||||||
# };
|
|
||||||
#
|
|
||||||
# Parameters:
|
|
||||||
# pkgs — nixpkgs package set (required)
|
|
||||||
# customSkills — path to a directory of skill subdirectories (optional)
|
|
||||||
# externalSkills — list of external skill sources (optional, default [])
|
|
||||||
# Each element is an attrset:
|
|
||||||
# src — path to repo root (flake input or local path)
|
|
||||||
# skillsDir — subdirectory containing skills (default "skills")
|
|
||||||
# selectSkills — list of skill names to include (default: all)
|
|
||||||
#
|
|
||||||
# Collision handling:
|
|
||||||
# Custom skills always take priority over external ones.
|
|
||||||
# Among external sources, earlier entries in the list take priority.
|
|
||||||
|
|
||||||
lib.mkOpencodeSkills =
|
# Collect all external skills, flattened.
|
||||||
{ pkgs
|
allExternal = lib.concatMap resolveExternal externalSkills;
|
||||||
, customSkills ? null
|
|
||||||
, externalSkills ? []
|
|
||||||
}:
|
|
||||||
let
|
|
||||||
# Resolve a single external source into a list of { name, path } entries.
|
|
||||||
resolveExternal = entry:
|
|
||||||
let
|
|
||||||
skillsRoot = "${entry.src}/${entry.skillsDir or "skills"}";
|
|
||||||
# List skill subdirectories (each must contain SKILL.md).
|
|
||||||
allSkillDirs = lib.pipe (builtins.readDir skillsRoot) [
|
|
||||||
(lib.filterAttrs (_: type: type == "directory"))
|
|
||||||
(dirs: lib.attrNames dirs)
|
|
||||||
];
|
|
||||||
selected =
|
|
||||||
if entry ? selectSkills
|
|
||||||
then builtins.filter (name: builtins.elem name entry.selectSkills) allSkillDirs
|
|
||||||
else allSkillDirs;
|
|
||||||
in
|
|
||||||
map (name: { inherit name; path = "${skillsRoot}/${name}"; }) selected;
|
|
||||||
|
|
||||||
# Collect all external skills, flattened.
|
# Collect custom skill names for collision detection.
|
||||||
allExternal = lib.concatMap resolveExternal externalSkills;
|
customSkillNames =
|
||||||
|
if customSkills != null
|
||||||
|
then lib.attrNames (lib.filterAttrs (_: type: type == "directory") (builtins.readDir customSkills))
|
||||||
|
else [];
|
||||||
|
|
||||||
# Collect custom skill names for collision detection.
|
# Filter out external skills that collide with custom ones.
|
||||||
customSkillNames =
|
# Among externals, keep first occurrence (earlier sources win).
|
||||||
if customSkills != null
|
filterExternals = externals: let
|
||||||
then lib.attrNames (lib.filterAttrs (_: type: type == "directory") (builtins.readDir customSkills))
|
go = acc: remaining:
|
||||||
else [];
|
if remaining == []
|
||||||
|
then acc.result
|
||||||
|
else let
|
||||||
|
head = builtins.head remaining;
|
||||||
|
tail = builtins.tail remaining;
|
||||||
|
isDuplicate = builtins.elem head.name acc.seen;
|
||||||
|
in
|
||||||
|
if isDuplicate
|
||||||
|
then go acc tail
|
||||||
|
else
|
||||||
|
go {
|
||||||
|
seen = acc.seen ++ [head.name];
|
||||||
|
result = acc.result ++ [head];
|
||||||
|
}
|
||||||
|
tail;
|
||||||
|
in
|
||||||
|
go {
|
||||||
|
seen = customSkillNames;
|
||||||
|
result = [];
|
||||||
|
}
|
||||||
|
externals;
|
||||||
|
|
||||||
# Filter out external skills that collide with custom ones.
|
filteredExternal = filterExternals allExternal;
|
||||||
# Among externals, keep first occurrence (earlier sources win).
|
|
||||||
filterExternals = externals:
|
|
||||||
let
|
|
||||||
go = acc: remaining:
|
|
||||||
if remaining == []
|
|
||||||
then acc.result
|
|
||||||
else
|
|
||||||
let
|
|
||||||
head = builtins.head remaining;
|
|
||||||
tail = builtins.tail remaining;
|
|
||||||
isDuplicate = builtins.elem head.name acc.seen;
|
|
||||||
in
|
|
||||||
if isDuplicate
|
|
||||||
then go acc tail
|
|
||||||
else go {
|
|
||||||
seen = acc.seen ++ [ head.name ];
|
|
||||||
result = acc.result ++ [ head ];
|
|
||||||
} tail;
|
|
||||||
in
|
|
||||||
go { seen = customSkillNames; result = []; } externals;
|
|
||||||
|
|
||||||
filteredExternal = filterExternals allExternal;
|
# Build a linkFarm entry for each external skill.
|
||||||
|
externalLinks =
|
||||||
|
map (skill: {
|
||||||
|
name = skill.name;
|
||||||
|
path = skill.path;
|
||||||
|
})
|
||||||
|
filteredExternal;
|
||||||
|
|
||||||
# Build a linkFarm entry for each external skill.
|
# Build a linkFarm entry for each custom skill.
|
||||||
externalLinks = map (skill: {
|
customLinks =
|
||||||
name = skill.name;
|
if customSkills != null
|
||||||
path = skill.path;
|
then
|
||||||
}) filteredExternal;
|
map (name: {
|
||||||
|
inherit name;
|
||||||
|
path = "${customSkills}/${name}";
|
||||||
|
})
|
||||||
|
customSkillNames
|
||||||
|
else [];
|
||||||
|
in
|
||||||
|
pkgs.linkFarm "opencode-skills" (customLinks ++ externalLinks);
|
||||||
|
|
||||||
# Build a linkFarm entry for each custom skill.
|
# ── Agent loader ───────────────────────────────────────────────
|
||||||
customLinks =
|
#
|
||||||
if customSkills != null
|
# Reads all canonical agents/*/agent.toml + agents/*/system-prompt.md
|
||||||
then map (name: {
|
# files and returns an attrset keyed by agent slug.
|
||||||
inherit name;
|
#
|
||||||
path = "${customSkills}/${name}";
|
# Each value has all fields from agent.toml plus:
|
||||||
}) customSkillNames
|
# systemPrompt — full content of system-prompt.md
|
||||||
else [];
|
#
|
||||||
|
# Usage:
|
||||||
|
# inputs.agents.lib.loadAgents.chiron.description
|
||||||
|
# inputs.agents.lib.loadAgents.chiron.systemPrompt
|
||||||
|
|
||||||
|
lib.loadAgents = let
|
||||||
|
agentDirs = builtins.attrNames (
|
||||||
|
lib.filterAttrs (_: t: t == "directory") (builtins.readDir ./agents)
|
||||||
|
);
|
||||||
|
isAgentDir = name: builtins.pathExists ./agents/${name}/agent.toml;
|
||||||
|
loadAgent = name:
|
||||||
|
(builtins.fromTOML (builtins.readFile ./agents/${name}/agent.toml))
|
||||||
|
// {systemPrompt = builtins.readFile ./agents/${name}/system-prompt.md;};
|
||||||
|
in
|
||||||
|
builtins.listToAttrs (
|
||||||
|
map (name: {
|
||||||
|
inherit name;
|
||||||
|
value = loadAgent name;
|
||||||
|
})
|
||||||
|
(builtins.filter isAgentDir agentDirs)
|
||||||
|
);
|
||||||
|
|
||||||
|
# ── Backward-compat agents.json bridge ────────────────────────
|
||||||
|
#
|
||||||
|
# Produces an attrset semantically equivalent to agents/agents.json,
|
||||||
|
# keyed by display name (e.g. "Chiron (Assistant)").
|
||||||
|
#
|
||||||
|
# Suitable for embedding into opencode config.json via home-manager:
|
||||||
|
# programs.opencode.settings.agent = inputs.agents.lib.agentsJson;
|
||||||
|
#
|
||||||
|
# Shape per agent:
|
||||||
|
# description — agent purpose string
|
||||||
|
# mode — "primary" | "subagent"
|
||||||
|
# model — LLM model ID (fixed: "zai-coding-plan/glm-5")
|
||||||
|
# permission — reconstructed permission object
|
||||||
|
# prompt — "{file:./prompts/<slug>.txt}"
|
||||||
|
|
||||||
|
lib.agentsJson = let
|
||||||
|
model = "zai-coding-plan/glm-5";
|
||||||
|
|
||||||
|
# Convert a single permission section from canonical TOML two-level
|
||||||
|
# (intent + rules[]) into the JSON nested object shape.
|
||||||
|
# intent-only → simple string
|
||||||
|
# intent+rules → { "*": intent, pattern: action, ... }
|
||||||
|
renderPermSection = section:
|
||||||
|
if !(section ? rules) || section.rules == []
|
||||||
|
then section.intent
|
||||||
|
else let
|
||||||
|
# Parse "pattern:action" — split on first colon only.
|
||||||
|
parseRule = ruleStr: let
|
||||||
|
colonIdx = lib.strings.stringLength (
|
||||||
|
builtins.head (lib.strings.splitString ":" ruleStr)
|
||||||
|
);
|
||||||
|
pattern = builtins.substring 0 colonIdx ruleStr;
|
||||||
|
action = builtins.substring (colonIdx + 1) (lib.strings.stringLength ruleStr) ruleStr;
|
||||||
|
in {
|
||||||
|
name = pattern;
|
||||||
|
value = action;
|
||||||
|
};
|
||||||
|
ruleAttrs = builtins.listToAttrs (map parseRule section.rules);
|
||||||
in
|
in
|
||||||
pkgs.linkFarm "opencode-skills" (customLinks ++ externalLinks);
|
{"*" = section.intent;} // ruleAttrs;
|
||||||
|
|
||||||
# ── Composable runtime ─────────────────────────────────────────
|
# Convert canonical permissions attrset to JSON permission object.
|
||||||
#
|
renderPermissions = perms:
|
||||||
# Runtime dependencies for skill scripts (Python packages, system
|
builtins.mapAttrs (_: renderPermSection) perms;
|
||||||
# tools). Include in home.packages or project devShells.
|
|
||||||
#
|
|
||||||
# Usage:
|
|
||||||
# home.packages = [ inputs.agents.packages.${system}.skills-runtime ];
|
|
||||||
# devShells.default = pkgs.mkShell {
|
|
||||||
# packages = [ inputs.agents.packages.${system}.skills-runtime ];
|
|
||||||
# };
|
|
||||||
|
|
||||||
packages = forAllSystems (system:
|
# Build one agent entry in the agentsJson shape.
|
||||||
let
|
renderAgent = slug: agent: {
|
||||||
pkgs = nixpkgs.legacyPackages.${system};
|
description = agent.description + ".";
|
||||||
|
mode = agent.mode;
|
||||||
|
model = model;
|
||||||
|
permission = renderPermissions agent.permissions;
|
||||||
|
prompt = "{file:./prompts/${slug}.txt}";
|
||||||
|
};
|
||||||
|
|
||||||
pythonEnv = pkgs.python3.withPackages (ps:
|
agents = self.lib.loadAgents;
|
||||||
with ps; [
|
in
|
||||||
# skill-creator: quick_validate.py
|
builtins.listToAttrs (
|
||||||
pyyaml
|
map
|
||||||
|
(slug: let
|
||||||
# xlsx: recalc.py
|
agent = builtins.getAttr slug agents;
|
||||||
openpyxl
|
|
||||||
|
|
||||||
# prompt-engineering-patterns: optimize-prompt.py
|
|
||||||
numpy
|
|
||||||
|
|
||||||
# pdf: multiple scripts
|
|
||||||
pypdf
|
|
||||||
pillow # PIL
|
|
||||||
pdf2image
|
|
||||||
|
|
||||||
# excalidraw: render_excalidraw.py
|
|
||||||
playwright
|
|
||||||
]);
|
|
||||||
in {
|
in {
|
||||||
skills-runtime = pkgs.buildEnv {
|
name = agent.display_name;
|
||||||
name = "opencode-skills-runtime";
|
value = renderAgent slug agent;
|
||||||
paths = [
|
})
|
||||||
pythonEnv
|
(builtins.attrNames agents)
|
||||||
pkgs.poppler-utils # pdf: pdftoppm/pdfinfo
|
);
|
||||||
pkgs.jq # shell scripts
|
|
||||||
pkgs.playwright-driver.browsers # excalidraw: chromium for rendering
|
|
||||||
];
|
|
||||||
};
|
|
||||||
});
|
|
||||||
|
|
||||||
# ── Dev shell ──────────────────────────────────────────────────
|
# ── Composable runtime ─────────────────────────────────────────
|
||||||
|
#
|
||||||
|
# Runtime dependencies for skill scripts (Python packages, system
|
||||||
|
# tools). Include in home.packages or project devShells.
|
||||||
|
#
|
||||||
|
# Usage:
|
||||||
|
# home.packages = [ inputs.agents.packages.${system}.skills-runtime ];
|
||||||
|
# devShells.default = pkgs.mkShell {
|
||||||
|
# packages = [ inputs.agents.packages.${system}.skills-runtime ];
|
||||||
|
# };
|
||||||
|
|
||||||
devShells = forAllSystems (system:
|
packages = forAllSystems (system: let
|
||||||
let
|
pkgs = nixpkgs.legacyPackages.${system};
|
||||||
pkgs = nixpkgs.legacyPackages.${system};
|
|
||||||
in {
|
|
||||||
default = pkgs.mkShell {
|
|
||||||
packages = [ self.packages.${system}.skills-runtime ];
|
|
||||||
|
|
||||||
env.PLAYWRIGHT_BROWSERS_PATH = "${pkgs.playwright-driver.browsers}";
|
pythonEnv = pkgs.python3.withPackages (ps:
|
||||||
|
with ps; [
|
||||||
|
# skill-creator: quick_validate.py
|
||||||
|
pyyaml
|
||||||
|
|
||||||
shellHook = ''
|
# xlsx: recalc.py
|
||||||
echo "🔧 AGENTS dev shell active — Python $(python3 --version 2>&1 | cut -d' ' -f2), $(jq --version)"
|
openpyxl
|
||||||
'';
|
|
||||||
};
|
# prompt-engineering-patterns: optimize-prompt.py
|
||||||
});
|
numpy
|
||||||
};
|
|
||||||
|
# pdf: multiple scripts
|
||||||
|
pypdf
|
||||||
|
pillow # PIL
|
||||||
|
pdf2image
|
||||||
|
|
||||||
|
# excalidraw: render_excalidraw.py
|
||||||
|
playwright
|
||||||
|
]);
|
||||||
|
in {
|
||||||
|
skills-runtime = pkgs.buildEnv {
|
||||||
|
name = "opencode-skills-runtime";
|
||||||
|
paths = [
|
||||||
|
pythonEnv
|
||||||
|
pkgs.poppler-utils # pdf: pdftoppm/pdfinfo
|
||||||
|
pkgs.jq # shell scripts
|
||||||
|
pkgs.playwright-driver.browsers # excalidraw: chromium for rendering
|
||||||
|
];
|
||||||
|
};
|
||||||
|
});
|
||||||
|
|
||||||
|
# ── Dev shell ──────────────────────────────────────────────────
|
||||||
|
|
||||||
|
devShells = forAllSystems (system: let
|
||||||
|
pkgs = nixpkgs.legacyPackages.${system};
|
||||||
|
in {
|
||||||
|
default = pkgs.mkShell {
|
||||||
|
packages = [self.packages.${system}.skills-runtime];
|
||||||
|
|
||||||
|
env.PLAYWRIGHT_BROWSERS_PATH = "${pkgs.playwright-driver.browsers}";
|
||||||
|
|
||||||
|
shellHook = ''
|
||||||
|
echo "🔧 AGENTS dev shell active — Python $(python3 --version 2>&1 | cut -d' ' -f2), $(jq --version)"
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
});
|
||||||
|
};
|
||||||
}
|
}
|
||||||
Reference in new issue
Block a user