@cachly-dev/mcp-server 0.10.258 → 0.10.259
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 +50 -2
- package/dist/src/embeddings.js +4 -4
- package/dist/src/gueltigkeit-version.js +4 -4
- package/dist/src/handlers/brain.js +33 -33
- package/dist/src/herkunft.js +1 -1
- package/dist/src/index.js +167 -167
- package/dist/src/kostprobe.js +3 -3
- package/dist/src/leser.js +1 -1
- package/dist/src/remote-zugang.js +2 -0
- package/dist/src/search.js +1 -1
- package/glama.json +1 -1
- package/hooks/cachly-ambient-einblendung.mjs +29 -28
- package/package.json +1 -1
- package/server.json +2 -2
package/dist/src/herkunft.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{createHash as
|
|
1
|
+
import{createHash as o}from"node:crypto";import{istMehrmandant as c,mandantKontext as u}from"./remote-zugang.js";let s="";function g(e,n){if(c())return;const t=String(e??"").trim(),r=String(n??"").trim();s=t?r?`${t}/${r}`:t:""}function l(){return s}function a(e){const n=e.split(".");if(n.length!==3)return"";try{const t=Buffer.from(n[1].replace(/-/g,"+").replace(/_/g,"/"),"base64").toString("utf8"),r=JSON.parse(t).sub;return typeof r=="string"?r.slice(0,64):""}catch{return""}}function m(e=process.env){if(c()){const i=u();return{agent:"mcp-http",...i?{principal:`key:${i.schluesselHash.slice(0,12)}`}:{},via:"mcp"}}const n=String(e.CACHLY_AGENT??"").trim()||s||"unbekannt",t=String(e.CACHLY_JWT??"").trim();let r;if(t){const i=a(t);r=i?`sub:${i}`:`key:${o("sha256").update(t).digest("hex").slice(0,12)}`}return{agent:n,...r?{principal:r}:{},via:"mcp"}}function h(e,n){const t=[];return e&&t.push(`@${e}`),n?.agent&&n.agent!=="unbekannt"&&t.push(`via ${n.agent}`),n?.principal&&t.push(n.principal),t.length>0?`\u{1F464} **Source:** ${t.join(" \xB7 ")}`:"\u{1F464} **Source:** Urheber unbekannt"}export{l as clientKennungFuerTests,m as ermittleQuelle,h as quelleZeile,g as setzeClientKennung};
|