shiroai 2.0.1 → 2.0.2

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.
Files changed (2) hide show
  1. package/cli.js +4 -4
  2. package/package.json +4 -10
package/cli.js CHANGED
@@ -16,7 +16,7 @@ const c = {
16
16
  };
17
17
 
18
18
  // ===== CONFIG =====
19
- const SERVER_URL = process.env.SHIROAI_SERVER || 'http://157.230.42.115:3000';
19
+ const API_URL = 'https://inference.do-ai.run/v1/chat/completions';
20
20
  const MODEL = 'deepseek-v4-pro';
21
21
  const CWD = process.cwd();
22
22
  const CONFIG_DIR = path.join(os.homedir(), '.shiroai');
@@ -259,7 +259,7 @@ function getProjectContext() {
259
259
 
260
260
  initMessages();
261
261
 
262
- // ===== STREAMING API (via server proxy) =====
262
+ // ===== STREAMING API =====
263
263
  function streamChat(msgs, tools) {
264
264
  return new Promise((resolve, reject) => {
265
265
  const body = JSON.stringify({
@@ -269,7 +269,7 @@ function streamChat(msgs, tools) {
269
269
  stream: true,
270
270
  max_tokens: 8192
271
271
  });
272
- const url = new URL(SERVER_URL + '/api/chat');
272
+ const url = new URL(API_URL);
273
273
  const client = url.protocol === 'https:' ? https : http;
274
274
 
275
275
  const req = client.request({
@@ -279,7 +279,7 @@ function streamChat(msgs, tools) {
279
279
  method: 'POST',
280
280
  headers: {
281
281
  'Content-Type': 'application/json',
282
- 'X-API-Key': API_KEY,
282
+ 'Authorization': `Bearer ${API_KEY}`,
283
283
  'Content-Length': Buffer.byteLength(body)
284
284
  }
285
285
  }, res => {
package/package.json CHANGED
@@ -1,18 +1,12 @@
1
1
  {
2
2
  "name": "shiroai",
3
- "version": "2.0.1",
3
+ "version": "2.0.2",
4
4
  "description": "AI coding agent for your terminal — reads, writes, edits files, runs commands",
5
- "bin": {
6
- "shiroai": "./cli.js"
7
- },
8
- "files": [
9
- "cli.js"
10
- ],
5
+ "bin": { "shiroai": "./cli.js" },
6
+ "files": ["cli.js"],
11
7
  "keywords": ["ai", "cli", "coding", "agent", "terminal", "copilot", "developer-tools", "shiroai"],
12
8
  "author": "ShiroAI",
13
9
  "license": "MIT",
14
10
  "homepage": "https://shiroai.dev",
15
- "engines": {
16
- "node": ">=16.0.0"
17
- }
11
+ "engines": { "node": ">=16.0.0" }
18
12
  }