opencode-m365-copilot 2.0.0 → 2.1.1
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 +36 -0
- package/dist/{agent-D4_Eut51.mjs → agent-Do_zx7Ev.mjs} +1 -1
- package/dist/cli.mjs +3 -3
- package/dist/{dist-BNzsla4k.mjs → dist-DoXU8l_x.mjs} +225 -140
- package/dist/{login-DcSFLsOo.mjs → login--nn76uPy.mjs} +3 -3
- package/dist/{otpauth.node-DaSYf7YH.mjs → otpauth.node-Cz2NJJEI.mjs} +4 -4
- package/dist/plugin.d.mts +20 -0
- package/dist/plugin.mjs +2 -2
- package/dist/{server-IXv9y_4x.mjs → server-MaGKSmnd.mjs} +99 -28
- package/dist/server.d.mts +11 -0
- package/dist/server.mjs +1 -1
- package/package.json +15 -11
package/README.md
CHANGED
|
@@ -195,6 +195,42 @@ A non-default tone (Claude, the reasoning tones) only takes effect when **no** a
|
|
|
195
195
|
attached — with one, M365 silently routes to GPT regardless. The proxy therefore attaches
|
|
196
196
|
the agent only on turns that carry tools, so plain chat reaches the model the tone selects.
|
|
197
197
|
|
|
198
|
+
### Reading your Microsoft 365 work
|
|
199
|
+
|
|
200
|
+
Two models ground the turn on your **own Microsoft 365 account**. Copilot's `WorkSearch`
|
|
201
|
+
runs server-side over the Microsoft Search index, so these span your whole work substrate,
|
|
202
|
+
not just mail:
|
|
203
|
+
|
|
204
|
+
| Model | Use |
|
|
205
|
+
|---|---|
|
|
206
|
+
| `m365/work` | Ask about your work — "what needs my attention first", "summarise the thread with X", "what did Jim message me on Teams", "find my recent sprint docs" |
|
|
207
|
+
| `m365/work-think` | The same, on a reasoning tone |
|
|
208
|
+
|
|
209
|
+
What `WorkSearch` reaches (all verified against a live tenant, except where noted):
|
|
210
|
+
|
|
211
|
+
| Source | Grounded? |
|
|
212
|
+
|---|---|
|
|
213
|
+
| Outlook **mail** and **calendar** | ✅ |
|
|
214
|
+
| **Teams** chats and channel messages | ✅ |
|
|
215
|
+
| **OneDrive** and **SharePoint** files | ✅ |
|
|
216
|
+
| **People** (colleagues, senders, managers) | ✅ |
|
|
217
|
+
| Third-party **Graph connectors** (Jira, ServiceNow, …) | ✅ *if your admin configured them* |
|
|
218
|
+
|
|
219
|
+
Select one in opencode (the model picker, or pin a `work` sub-agent to it) when you want
|
|
220
|
+
this context; every other model stays coding/web-only and never reaches your account. A
|
|
221
|
+
grounded turn switches the request to the Outlook side-pane scenario, sends that surface's
|
|
222
|
+
feature variants, and attaches the built-in agent with the `WorkSearch` capability — the
|
|
223
|
+
combination that actually grounds on the signed-in account — then strips Copilot's inline
|
|
224
|
+
citation markers from the reply. Bias toward one source by saying so ("in Teams, …", "in my
|
|
225
|
+
OneDrive, …").
|
|
226
|
+
|
|
227
|
+
These models are for **reading and synthesis** — ask-your-work Q&A. A grounded turn carries
|
|
228
|
+
**no tools**: the proxy drops opencode's toolset for these models, so the fenced tool
|
|
229
|
+
instructions are never attached and no tool-call parsing runs on the reply — Copilot brings
|
|
230
|
+
its own built-in agent instead. Keep a coding model selected for coding, and switch to
|
|
231
|
+
`m365/work` to ask about your mail, Teams or files. Read-only: Copilot searches and
|
|
232
|
+
summarises, it does not send a message or edit a file.
|
|
233
|
+
|
|
198
234
|
## Authentication
|
|
199
235
|
|
|
200
236
|
Sign-in is a CLI concern, never the plugin's: the plugin only refreshes silently and asks
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { _ as createLogger, b as AGENT_FILE, d as POWERPLATFORM_SCOPE, l as BAP_SCOPE, y as writePrivateFile } from "./server-
|
|
1
|
+
import { _ as createLogger, b as AGENT_FILE, d as POWERPLATFORM_SCOPE, l as BAP_SCOPE, y as writePrivateFile } from "./server-MaGKSmnd.mjs";
|
|
2
2
|
import { readFileSync } from "node:fs";
|
|
3
3
|
import { createHash } from "node:crypto";
|
|
4
4
|
// src/agent.ts
|
package/dist/cli.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import { A as DEFAULT_MODEL, C as SECRETS_FILE, O as mergeOpencodeConfig, S as CONFIG_DIR, T as PROVIDER_ID, a as startServer, b as AGENT_FILE, g as createTokenClient, j as LOCAL_TITLE_MODEL, x as CACHE_FILE } from "./server-
|
|
3
|
-
import { t as getOrCreateAgent } from "./agent-
|
|
2
|
+
import { A as DEFAULT_MODEL, C as SECRETS_FILE, O as mergeOpencodeConfig, S as CONFIG_DIR, T as PROVIDER_ID, a as startServer, b as AGENT_FILE, g as createTokenClient, j as LOCAL_TITLE_MODEL, x as CACHE_FILE } from "./server-MaGKSmnd.mjs";
|
|
3
|
+
import { t as getOrCreateAgent } from "./agent-Do_zx7Ev.mjs";
|
|
4
4
|
import { homedir } from "node:os";
|
|
5
5
|
import { dirname, join, resolve } from "node:path";
|
|
6
6
|
import { copyFileSync, existsSync, mkdirSync, readFileSync, writeFileSync } from "node:fs";
|
|
@@ -46,7 +46,7 @@ to complete SSO/MFA by hand once — the only option on tenants with push-only
|
|
|
46
46
|
MFA, FIDO2, or a federated IdP.`);
|
|
47
47
|
}
|
|
48
48
|
async function doLogin(args) {
|
|
49
|
-
const { login } = await import("./login
|
|
49
|
+
const { login } = await import("./login--nn76uPy.mjs");
|
|
50
50
|
const interactive = args.includes("--interactive");
|
|
51
51
|
try {
|
|
52
52
|
const account = await login({
|