u-foo 1.2.8 → 1.2.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/README.zh-CN.md +1 -1
- package/package.json +1 -1
- package/src/agent/ucodeRuntimeConfig.js +6 -2
- package/src/code/runtime.js +1 -1
- package/src/code/sessionStore.js +1 -1
package/README.md
CHANGED
|
@@ -156,7 +156,7 @@ Configure AI providers in `.ufoo/config.json`:
|
|
|
156
156
|
}
|
|
157
157
|
```
|
|
158
158
|
|
|
159
|
-
`ucode` writes these into a dedicated runtime directory (`.ufoo/agent/ucode/
|
|
159
|
+
`ucode` writes these into a dedicated runtime directory (`.ufoo/agent/ucode/config`) and uses them for native planner/engine calls.
|
|
160
160
|
|
|
161
161
|
## Architecture
|
|
162
162
|
|
package/README.zh-CN.md
CHANGED
package/package.json
CHANGED
|
@@ -30,12 +30,15 @@ function resolveRuntimeValues({
|
|
|
30
30
|
const model = String(env.UFOO_UCODE_MODEL || config.ucodeModel || "").trim();
|
|
31
31
|
const apiKey = String(env.UFOO_UCODE_API_KEY || config.ucodeApiKey || "").trim();
|
|
32
32
|
const baseUrl = String(env.UFOO_UCODE_BASE_URL || config.ucodeBaseUrl || "").trim();
|
|
33
|
+
const newDefault = path.join(root, ".ufoo", "agent", "ucode", "config");
|
|
34
|
+
const legacyDefault = path.join(root, ".ufoo", "agent", "ucode", "pi-agent");
|
|
33
35
|
const agentDir = path.resolve(
|
|
34
36
|
String(
|
|
35
|
-
env.
|
|
37
|
+
env.UFOO_UCODE_CONFIG_DIR
|
|
38
|
+
|| env.PI_CODING_AGENT_DIR
|
|
36
39
|
|| env.UFOO_UCODE_AGENT_DIR
|
|
37
40
|
|| config.ucodeAgentDir
|
|
38
|
-
||
|
|
41
|
+
|| (fs.existsSync(legacyDefault) && !fs.existsSync(newDefault) ? legacyDefault : newDefault)
|
|
39
42
|
).trim()
|
|
40
43
|
);
|
|
41
44
|
return {
|
|
@@ -116,6 +119,7 @@ function prepareUcodeRuntimeConfig({
|
|
|
116
119
|
return {
|
|
117
120
|
...inspection,
|
|
118
121
|
env: {
|
|
122
|
+
UFOO_UCODE_CONFIG_DIR: inspection.agentDir,
|
|
119
123
|
PI_CODING_AGENT_DIR: inspection.agentDir,
|
|
120
124
|
},
|
|
121
125
|
};
|
package/src/code/runtime.js
CHANGED
|
@@ -4,7 +4,7 @@ const { runToolCall } = require("./dispatch");
|
|
|
4
4
|
|
|
5
5
|
function getRuntimePaths(projectRoot = process.cwd()) {
|
|
6
6
|
const root = path.resolve(projectRoot || process.cwd());
|
|
7
|
-
const runtimeDir = path.join(root, ".ufoo", "agent", "ucode
|
|
7
|
+
const runtimeDir = path.join(root, ".ufoo", "agent", "ucode");
|
|
8
8
|
return {
|
|
9
9
|
projectRoot: root,
|
|
10
10
|
runtimeDir,
|
package/src/code/sessionStore.js
CHANGED
|
@@ -4,7 +4,7 @@ const { randomUUID } = require("crypto");
|
|
|
4
4
|
|
|
5
5
|
function getSessionsDir(workspaceRoot = process.cwd()) {
|
|
6
6
|
const root = path.resolve(workspaceRoot || process.cwd());
|
|
7
|
-
return path.join(root, ".ufoo", "agent", "ucode
|
|
7
|
+
return path.join(root, ".ufoo", "agent", "ucode", "sessions");
|
|
8
8
|
}
|
|
9
9
|
|
|
10
10
|
function normalizeSessionId(value = "") {
|