chatModel.ts ×8

Frontier kind: Code frontier

unlabeled · c_cab538a7f326

50 tests · 44115 LOC · 194 files · introduces 0 tests · 24 LOC · 1 file

Introduces — evidence that enters the hierarchy at this concept

Code
8 ranges24 lines · 1 files
Tests
0 tests

Contains — complete concept membership

All code (extent)
3964 ranges44115 lines · 194 files · Browse complete extent
All tests (intent)
50 testsBrowse complete intent

Neighbourhood graph

The orange circle is the focus. Violet and green circles are every ancestor and descendant, broader and narrower, at any distance; blue squares and pink diamonds are the introduced files and exact introduced tests of every visible concept, not only the focus's. Arrows point from broader to narrower concepts and bridge only concepts omitted from this view. Undirected links show source or test introduction. Concept and file size follows LOC; exact test nodes use test-count units.

Introduced files, introduced tests, and structurally relevant concept specialization

In the embedded map, ordinary wheel input scrolls the page; use the visible controls to zoom and drag to pan. Open the full-screen map for canvas navigation: wheel pans, Ctrl/Command plus wheel zooms, and arrow keys pan when this region is focused. On touch screens, open the full-screen map to pan or pinch. If JavaScript or WebGL is unavailable, use the native relationship evidence on this page.

Graph controls are ready.

Interactive rendering requires JavaScript and WebGL. Use the native relationship evidence on this page while the interactive map is unavailable.

Native relationship evidence

Every exact file and test below is linked only from the concept that introduces it.

Introduced tests

Every collected test enters the hierarchy at exactly one concept.

No tests are introduced at this concept. Its intent tests are introduced by other concepts.

Introduced code

Every collected source range enters the hierarchy at exactly one concept.

1 file ranked by introduced lines: 24 introduced LOC across 8 ranges. Expand a file to inspect source; the > gutter marks introduced lines.

src/vs/workbench/contrib/chat/common/model/chatModel.ts 24 introduced LOC · 8 ranges

Open complete file

510
511 toString(): string {
512 > if (this._responseRepr === undefined) { chatModel.ts
513 > this._responseRepr = this.computeRepr();
514 > }
515 > return this._responseRepr;
516 > }
517
518 /**
601
602 protected computeRepr(): string {
603 > return this.partsToRepr(this._responseParts); chatModel.ts
604 > }
605
606 private partsToRepr(parts: readonly IChatProgressResponseContent[]): string {
607 > const blocks: string[] = []; chatModel.ts
608 > let currentBlockSegments: string[] = [];
609 > let hasEditGroupsAfterLastClear = false;
610 >
611 > for (const part of parts) {
612 let segment: { text: string; isBlock?: boolean } | undefined;
613 switch (part.kind) {
690 }
691 }
692 > chatModel.ts
693 > if (currentBlockSegments.length) {
694 blocks.push(currentBlockSegments.join(''));
695 }
696 > chatModel.ts
697 > // Add consolidated edit summary at the end if there were any edit groups after the last clear
698 > if (hasEditGroupsAfterLastClear) {
699 blocks.push(localize('editsSummary', "Made changes."));
700 }
701 > chatModel.ts
702 > return blocks.join('\n\n');
703 > }
704
705 private inlineRefToRepr(part: IChatContentInlineReference) {
1087
1088 protected override computeRepr(): string {
1089 > let repr = super.computeRepr(); chatModel.ts
1090 > if (this._citations.length) {
1091 repr += '\n\n' + getCodeCitationsMessage(this._citations);
1092 }
1093 > return repr; chatModel.ts
1094 > }
1095
1096 private _contentChanged(quiet?: boolean) {