fix(coding-agent): unify source provenance, closes #1734
This commit is contained in:
@@ -5,7 +5,13 @@
|
||||
* Discover, filter, merge, or replace them.
|
||||
*/
|
||||
|
||||
import { createAgentSession, DefaultResourceLoader, SessionManager, type Skill } from "@mariozechner/pi-coding-agent";
|
||||
import {
|
||||
createAgentSession,
|
||||
createSyntheticSourceInfo,
|
||||
DefaultResourceLoader,
|
||||
SessionManager,
|
||||
type Skill,
|
||||
} from "@mariozechner/pi-coding-agent";
|
||||
|
||||
// Or define custom skills inline
|
||||
const customSkill: Skill = {
|
||||
@@ -13,7 +19,7 @@ const customSkill: Skill = {
|
||||
description: "Custom project instructions",
|
||||
filePath: "/virtual/SKILL.md",
|
||||
baseDir: "/virtual",
|
||||
source: "path",
|
||||
sourceInfo: createSyntheticSourceInfo("/virtual/SKILL.md", { source: "sdk" }),
|
||||
disableModelInvocation: false,
|
||||
};
|
||||
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
|
||||
import {
|
||||
createAgentSession,
|
||||
createSyntheticSourceInfo,
|
||||
DefaultResourceLoader,
|
||||
type PromptTemplate,
|
||||
SessionManager,
|
||||
@@ -15,8 +16,8 @@ import {
|
||||
const deployTemplate: PromptTemplate = {
|
||||
name: "deploy",
|
||||
description: "Deploy the application",
|
||||
source: "path",
|
||||
filePath: "/virtual/prompts/deploy.md",
|
||||
sourceInfo: createSyntheticSourceInfo("/virtual/prompts/deploy.md", { source: "sdk" }),
|
||||
content: `# Deploy Instructions
|
||||
|
||||
1. Build: npm run build
|
||||
|
||||
Reference in New Issue
Block a user