Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
43 commits
Select commit Hold shift + click to select a range
d9902aa
Merge pull request #564 from codercops/production
anurag629 Oct 31, 2026
1a0ce80
fix(core): honor HTTP-date Retry-After values (#552)
piyusshhjangid Oct 31, 2026
2223a16
fix(server): block trailing-dot local webhook hosts (#562)
piyusshhjangid Oct 31, 2026
6a257d5
fix: expand lint package paths on Windows (#565)
piyusshhjangid Oct 31, 2026
b2ae289
feat(ingest,cli): contextual retrieval, a model-written context for e…
Saifjafri212213 Oct 31, 2026
d8d6941
fix(ingest): keep a # that ends a heading when it is part of the titl…
Saifjafri212213 Oct 31, 2026
dde7a78
feat(core): add redactPII() to take personal data out of text (#568) …
Saifjafri212213 Oct 31, 2026
53c71ca
docs: add test-before-launch guide for bots (#570)
anurag2787 Nov 1, 2026
46d01e7
fix(widget): keep line breaks in the visitor's messages (#577)
prakashNalla Nov 2, 2026
e0adbe7
feat(core,server): record whether each reply answered the question (#…
anurag629 Nov 4, 2026
ac269f4
fix(ingest): run on Cloudflare Workers (#587)
anurag629 Nov 4, 2026
32c87af
fix(core): validate topN in cohere and voyage rerankers (#582) (#589)
bhushan4work Nov 6, 2026
7259529
feat(cli): add junit reporter and output support (#590)
kachamsiddarth Nov 6, 2026
8a9adef
feat(ingest): crawl discovery source (#586) (#588)
bhushan4work Nov 9, 2026
6c9a084
feat(server): chatcopsNext() catch-all route adapter for Next.js (#57…
Saifjafri212213 Nov 9, 2026
b90d9d7
feat(react): add <ChatCops> component and useChatCops() hook (#573) (…
Saifjafri212213 Nov 9, 2026
5dbb63f
fix(widget): drop the whole language tag from a code block (#579)
prakashNalla Nov 10, 2026
715f6a5
feat(cli): add GitHub Actions reporter (#593)
kachamsiddarth Nov 10, 2026
7b4bb5a
chore(deps-dev): bump vite from 6.4.3 to 6.4.5 (#572)
dependabot[bot] Nov 11, 2026
c380dad
chore(deps-dev): bump happy-dom from 20.14.5 to 21.0.4 (#584)
dependabot[bot] Nov 11, 2026
3a371d7
Added docs for astro nuxt and sveltekit (#591)
anurag2787 Nov 11, 2026
4768e34
chore(widget): raise the panel budget to 19.2 kB (#596)
anurag629 Nov 12, 2026
a64c9fb
feat(widget): show pill when new messages arrive while scrolled up (#…
bhushan4work Nov 12, 2026
bc8ed4c
fix(server): validate rateLimit.windowMs at startup (#452) (#594)
bhushan4work Nov 13, 2026
395096f
fix(cli): resolve GitHub annotations from workspace (#600)
bhushan4work Nov 13, 2026
105bf39
fix(core): default non-finite retriever limits (#601)
bhushan4work Nov 13, 2026
14255a5
chore(deps): bump astro from 7.3.5 to 7.4.7 (#603)
dependabot[bot] Nov 14, 2026
878f035
chore(deps): update body-parser and zod in the lockfile (#605)
anurag629 Nov 15, 2026
4d5179f
docs: document remaining widget locale strings (#604)
bhushan4work Nov 15, 2026
0db15fe
docs: give the widget's real size and language count (#616)
anurag629 Nov 15, 2026
735b6b5
chore(website): cap the docs chat's daily token use (#618)
anurag629 Nov 16, 2026
1ac65a2
feat(cli): run tests against HTTP servers (#602)
bhushan4work Nov 16, 2026
a034d7a
feat(widget): add missing Urdu translations (#55) (#606)
Saifjafri212213 Nov 16, 2026
44228bf
i18n: fill remaining locale strings for #55 (#607)
bhushan4work Nov 16, 2026
9759af3
Require non-blank trimmed name and projectDetails in capture_lead (#617)
joshuaallgaier2-cmd Nov 17, 2026
99701ee
fix(widget): improve inline accessibility (#620)
bhushan4work Nov 17, 2026
efe0064
chore(core): upgrade @google/genai to 3.3 (#597)
anurag629 Nov 18, 2026
98f8cb7
chore: point Dependabot at the repo root (#623)
anurag629 Nov 18, 2026
524f5e6
fix(widget): validate on submit and focus first invalid field (#622)
bhushan4work Nov 18, 2026
8c16fc3
test(widget): pass the widget tests on Node 25 (#211)
anurag629 Nov 18, 2026
d569c86
fix(widget): keep focus in the popup on the consent notice and menu c…
bhushan4work Nov 19, 2026
fc090e0
chore(deps): bump the provider-sdks group with 2 updates (#624)
dependabot[bot] Nov 19, 2026
2b2a3c0
docs: rebuild the docs bot index before the release, re-record its ev…
anurag629 Nov 19, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .changeset/answered-signal.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
'@chatcops/core': minor
'@chatcops/server': minor
---

Each finished reply is saved with `metadata.answered`, and `metadata.unansweredReason` (`refusal`, `no_retrieval` or `no_citation`) when it didn't answer, for an answer rate and a list of questions the knowledge doesn't cover. `checkAnswered()` in `@chatcops/core` is the same check.
5 changes: 5 additions & 0 deletions .changeset/bright-retries-retry-after-core.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@chatcops/core": patch
---

Honor HTTP-date values in provider Retry-After headers.
5 changes: 5 additions & 0 deletions .changeset/cli-contextualize.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@chatcops/cli": minor
---

`chatcops ingest --contextualize` has the model in `ingest.contextualize.provider` write a short context for each chunk before it is embedded, and stops with a message when the config has none. Without the flag a run never asks a model. The summary and `--json` report the chunks that got a context and the model tokens used.
5 changes: 5 additions & 0 deletions .changeset/cli-github-reporter.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@chatcops/cli": minor
---

Add a GitHub Actions reporter with failure annotations and a Markdown job summary.
5 changes: 5 additions & 0 deletions .changeset/cli-junit-output.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@chatcops/cli": minor
---

Add a JUnit XML reporter and output-file support to chatcops test.
5 changes: 5 additions & 0 deletions .changeset/core-genai-3.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@chatcops/core": patch
---

Upgrade `@google/genai` to 3.3. Gemini requests still go to the `v1beta` API, as they did on 2.x.
5 changes: 5 additions & 0 deletions .changeset/core-provider-sdks.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@chatcops/core": patch
---

Update `@anthropic-ai/sdk` to 1.8 and `openai` to 7.57.
5 changes: 5 additions & 0 deletions .changeset/core-redact-pii.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@chatcops/core": minor
---

Add `redactPII()`, which takes email addresses, phone numbers, card numbers, IBANs and IP addresses out of text.
6 changes: 6 additions & 0 deletions .changeset/crawl-discovery.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
'@chatcops/ingest': minor
'@chatcops/cli': minor
---

Support crawl ingestion sources starting from a URL and following same-origin links breadth-first with maxDepth, maxPages, deduplication, robots.txt compliance, and cached HTML reuse during extraction. Add --crawl to the chatcops ingest command and crawl: URLs to --source.
5 changes: 5 additions & 0 deletions .changeset/fence-language-tag.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@chatcops/widget": patch
---

A code block tagged `c++`, `c#` or `objective-c` no longer shows part of the tag as its first line, and a one-line code block keeps all of its text.
5 changes: 5 additions & 0 deletions .changeset/focus-popup-consent-menu.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@chatcops/widget": patch
---

Keep focus inside the popup when it opens on the consent notice and after choosing an item from the header menu.
5 changes: 5 additions & 0 deletions .changeset/github-annotation-workspace.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@chatcops/cli": patch
---

Fix GitHub annotations for tests run from a subfolder.
5 changes: 5 additions & 0 deletions .changeset/http-test-runner.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@chatcops/cli": minor
---

Run evals against a remote ChatCops server with `--url` and repeatable `--header` options.
5 changes: 5 additions & 0 deletions .changeset/ingest-contextualize.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@chatcops/ingest": minor
---

`contextualize: { provider }` has a model write a short context for each chunk before it is embedded (contextual retrieval): the context is embedded with the chunk, the stored text stays the chunk, and the context is kept in its metadata. The page goes in the system prompt so a provider that caches prompts reads it once, a dry run asks no model, and turning it on or off, or changing the model, embeds pages again. `IngestStats` gains `contextualized` and `modelTokens`.
5 changes: 5 additions & 0 deletions .changeset/ingest-heading-trailing-hash.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@chatcops/ingest": patch
---

A heading that ends in `#` keeps it when the `#` is part of the title: `## Using C#` is "Using C#" in the heading path and the chunk's `section`, no longer "Using C". A closing run of `#` is dropped only when a space comes before it (`## Notes ##`), as in CommonMark.
5 changes: 5 additions & 0 deletions .changeset/ingest-on-workers.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@chatcops/ingest': patch
---

Ingest runs on Cloudflare Workers. Pages were converted to Markdown by turndown's browser build there, which needs a `document` a Worker doesn't have, so every page failed with "document is not defined". turndown now gets a page parsed by domino, the parser its Node build already uses, so the Markdown is the same everywhere.
5 changes: 5 additions & 0 deletions .changeset/lead-capture-trim.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@chatcops/core": patch
---

Require non-blank trimmed `name` and `projectDetails` in `capture_lead`, and name the offending field in validation errors.
5 changes: 5 additions & 0 deletions .changeset/local-hostnames-webhook-dot.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@chatcops/server": patch
---

Block trailing-dot localhost and internal webhook hostnames.
5 changes: 5 additions & 0 deletions .changeset/prechat-submit-validation-focus.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@chatcops/widget": patch
---

Keep pre-chat submit button enabled, show all field errors and focus the first invalid field on submit, and hide the required asterisk marker from screen readers.
5 changes: 5 additions & 0 deletions .changeset/quiet-languages-translate.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@chatcops/widget": patch
---

Fill remaining widget locale strings.
5 changes: 5 additions & 0 deletions .changeset/quiet-regions-focus.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@chatcops/widget": patch
---

Keep inline pre-chat forms from taking focus and expose inline panels as named regions.
6 changes: 6 additions & 0 deletions .changeset/react-component.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"@chatcops/react": minor
---

Add `@chatcops/react` with `<ChatCops>` component and `useChatCops()` hook for React and Next.js applications.

5 changes: 5 additions & 0 deletions .changeset/reranker-topn-validation.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@chatcops/core": patch
---

Validate topN in cohereReranker and voyageReranker to immediately return an empty array for NaN.
5 changes: 5 additions & 0 deletions .changeset/retriever-finite-limits.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@chatcops/core": patch
---

Use safe defaults when retriever limits are not finite numbers.
5 changes: 5 additions & 0 deletions .changeset/server-chatcops-next.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@chatcops/server": minor
---

Add `chatcopsNext()`, a single catch-all route adapter for Next.js App Router that handles both chat and session requests.
5 changes: 5 additions & 0 deletions .changeset/stream-new-reply-pill.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@chatcops/widget": minor
---

Show a "New reply" pill when new messages or reply text arrive while scrolled up.
5 changes: 5 additions & 0 deletions .changeset/user-message-newlines.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@chatcops/widget": patch
---

A visitor's message keeps the line breaks they typed with Shift+Enter instead of showing as one line.
5 changes: 5 additions & 0 deletions .changeset/validate-ratelimit-core.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@chatcops/core": patch
---

Validate rate limiter limits and windows as finite numbers greater than 0.
5 changes: 5 additions & 0 deletions .changeset/validate-ratelimit-windowms.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@chatcops/server": patch
---

Validate `rateLimit.maxRequests` and `rateLimit.windowMs` at startup in `createChatHandler`, rejecting values that are not finite numbers greater than 0.
5 changes: 5 additions & 0 deletions .changeset/widget-ur-strings.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@chatcops/widget": patch
---

Add missing widget translations for Urdu (`ur.ts`).
7 changes: 6 additions & 1 deletion .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,15 @@
# Merging one of these PRs: add a changeset for @chatcops/core (`pnpm changeset`)
# so the new SDK version reaches npm, and run the live provider check if the
# bump is a new major.
#
# The SDKs are dependencies of packages/core, but the directory is the repo
# root: that's where pnpm-lock.yaml and pnpm-workspace.yaml are, and an update
# job pointed at packages/core can't see them, so its PRs change package.json
# without the lockfile and fail at install (#592, #621).
version: 2
updates:
- package-ecosystem: npm
directory: /packages/core
directory: /
schedule:
interval: weekly
day: monday
Expand Down
8 changes: 7 additions & 1 deletion .size-limit.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
{
"name": "widget, chat panel (chatcops.panel.js, loaded on open)",
"path": "packages/widget/dist/chatcops.panel.js",
"limit": "19 KB",
"limit": "19.2 KB",
"gzip": true
},
{
Expand All @@ -34,5 +34,11 @@
"path": "packages/widget/dist/chatcops.esm.js",
"limit": "32 KB",
"gzip": true
},
{
"name": "react (@chatcops/react)",
"path": "packages/react/dist/index.js",
"limit": "1.5 KB",
"gzip": true
}
]
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ ANTHROPIC_API_KEY=sk-... npx tsx src/examples/express-server.ts

`npx` downloads `tsx` the first time.

The widget has a size budget, gzipped: 5 kB for the script tag loader (`dist/chatcops.min.js`), 19 kB for the chat panel it loads when the chat opens (`dist/chatcops.panel.js`), 2 kB for the pre-chat form chunk, 23 kB for the single-file build (`dist/chatcops.full.min.js`) and 32 kB for the unminified ESM build. CI checks them with `pnpm size` after a build (limits in `.size-limit.json`). To save bytes, the minifier renames the private class members listed in `packages/widget/mangle.ts`. A name can go on that list only if the code touches it through `this` and nowhere else, which `tests/mangle.test.ts` checks. A config field, a request body key or a DOM property renamed there would break only the CDN build.
The widget has a size budget, gzipped: 5 kB for the script tag loader (`dist/chatcops.min.js`), 19.2 kB for the chat panel it loads when the chat opens (`dist/chatcops.panel.js`), 2 kB for the pre-chat form chunk, 23 kB for the single-file build (`dist/chatcops.full.min.js`) and 32 kB for the unminified ESM build. CI checks them with `pnpm size` after a build (limits in `.size-limit.json`). To save bytes, the minifier renames the private class members listed in `packages/widget/mangle.ts`. A name can go on that list only if the code touches it through `this` and nowhere else, which `tests/mangle.test.ts` checks. A config field, a request body key or a DOM property renamed there would break only the CDN build.

### Browser tests

Expand Down
8 changes: 7 additions & 1 deletion api/cli.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ export interface Reporter {
}

export type ReporterFactory = (output: ReporterOutput, options: {
cwd?: string;
env?: Record<string, string | undefined>;
verbose?: boolean;
}) => Reporter;
Expand All @@ -92,7 +93,7 @@ export interface ReporterOutput {

export declare const REPORTERS: Map<string, ReporterFactory>;

export declare function runFixtures(server: ChatCopsServerConfig, fixtures: FixtureJob[], options?: RunOptions): Promise<TestResult[]>;
export declare function runFixtures(server: ChatCopsServerConfig | undefined, fixtures: FixtureJob[], options?: RunOptions): Promise<TestResult[]>;

export interface RunOptions {
concurrency?: number;
Expand All @@ -103,6 +104,11 @@ export interface RunOptions {
model?: string;
prices?: Prices;
spend?: Spend;
url?: string;
headers?: Array<[
string,
string
]>;
}

export interface TestCase {
Expand Down
26 changes: 26 additions & 0 deletions api/core.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,22 @@ export interface AnalyticsStats {
eventCounts: Record<string, number>;
}

export interface AnswerCheck {
reply: string;
retrieval?: {
chunks: number;
minScore?: number;
topScore?: number;
};
cited?: number;
phrases?: string[];
}

export interface AnswerVerdict {
answered: boolean;
reason?: UnansweredReason;
}

export interface AppendOptions {
expectedVersion?: number;
metadata?: Record<string, unknown>;
Expand Down Expand Up @@ -170,6 +186,8 @@ export interface ChatTool {
emits?(result: ToolResult): MessagePart[];
}

export declare function checkAnswered(input: AnswerCheck): AnswerVerdict;

export declare class CitationParser {
constructor(count: number);
push(delta: string): {
Expand Down Expand Up @@ -709,6 +727,12 @@ export interface ReasoningPart {

export declare function reciprocalRankFusion(lists: ScoredRecord[][], k?: number): RetrievedChunk[];

export interface RedactOptions {
patterns?: RegExp[];
}

export declare function redactPII(text: string, options?: RedactOptions): string;

export declare class RefusalError extends Error {
constructor();
}
Expand Down Expand Up @@ -933,6 +957,8 @@ export interface TurnResult {
error?: unknown;
}

export type UnansweredReason = 'refusal' | 'no_retrieval' | 'no_citation';

export declare function uniqueChunks(chunks: RetrievedChunk[]): RetrievedChunk[];

export declare function validateTools(tools: readonly ToolDefinition[]): void;
Expand Down
17 changes: 17 additions & 0 deletions api/ingest.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ export declare function discover(sources: IngestSource[], options: DiscoverOptio
export interface DiscoveredPage {
url: string;
file?: string;
html?: string;
}

export interface DiscoverOptions {
Expand All @@ -35,6 +36,9 @@ export interface DiscoverOptions {
timeoutMs: number;
include?: string[];
exclude?: string[];
concurrency?: number;
respectRobots?: boolean;
maxPages?: number;
}

export interface Discovery {
Expand Down Expand Up @@ -79,6 +83,9 @@ export interface IngestConfig {
store: VectorStore;
manifest: KeyValueStore;
metadata?: (doc: ExtractedDoc) => Record<string, MetadataValue>;
contextualize?: false | {
provider: ProviderConfig | AIProvider;
};
dryRun?: boolean;
force?: boolean;
prune?: boolean;
Expand Down Expand Up @@ -111,6 +118,11 @@ export type IngestSource = {
baseUrl: string;
path: string;
type: 'directory';
} | {
maxDepth?: number;
maxPages?: number;
type: 'crawl';
url: string;
};

export interface IngestStats {
Expand All @@ -122,6 +134,11 @@ export interface IngestStats {
pruned: number;
chunks: number;
embedded: number;
contextualized: number;
modelTokens: {
inputTokens: number;
outputTokens: number;
};
errors: string[];
pruneSkipped?: string;
}
Expand Down
Loading
Loading