git-coco 0.3.3 → 0.4.0
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/dist/commands/changelog/handler.d.ts +3 -0
- package/dist/commands/changelog/index.d.ts +10 -0
- package/dist/commands/changelog/options.d.ts +16 -0
- package/dist/commands/commit/handler.d.ts +3 -0
- package/dist/commands/commit/index.d.ts +10 -0
- package/dist/commands/commit/options.d.ts +15 -0
- package/dist/commands/types.d.ts +14 -0
- package/dist/index.d.ts +1 -3
- package/dist/index.esm.mjs +689 -470
- package/dist/index.esm.mjs.map +1 -1
- package/dist/index.js +689 -471
- package/dist/lib/langchain/executeChain.d.ts +6 -0
- package/dist/lib/langchain/prompts/changelog.d.ts +3 -0
- package/dist/lib/langchain/utils.d.ts +2 -2
- package/dist/lib/parsers/default/index.d.ts +2 -2
- package/dist/lib/parsers/default/utils/createDiffTree.d.ts +1 -0
- package/dist/lib/parsers/noResult.d.ts +4 -2
- package/dist/lib/simple-git/getChanges.d.ts +2 -2
- package/dist/lib/simple-git/getChangesByCommit.d.ts +2 -2
- package/dist/lib/simple-git/getCommitLogRange.d.ts +7 -0
- package/dist/lib/simple-git/getDiff.d.ts +2 -2
- package/dist/lib/simple-git/getStatus.d.ts +1 -1
- package/dist/lib/simple-git/getSummaryText.d.ts +1 -1
- package/dist/lib/types.d.ts +19 -8
- package/dist/lib/ui/editPrompt.d.ts +2 -0
- package/dist/lib/ui/editResult.d.ts +2 -0
- package/dist/lib/ui/generateAndReviewLoop.d.ts +16 -0
- package/dist/lib/ui/getUserReviewDecision.d.ts +2 -0
- package/dist/lib/ui/handleResult.d.ts +5 -0
- package/dist/lib/ui/helpers.d.ts +3 -0
- package/dist/lib/ui/logResult.d.ts +1 -0
- package/dist/lib/ui/logSuccess.d.ts +1 -0
- package/dist/stats.html +1 -1
- package/package.json +3 -3
- package/dist/commands/commit.d.ts +0 -16
- package/dist/lib/langchain/chains/llm.d.ts +0 -6
- package/dist/lib/ui.d.ts +0 -24
- package/dist/types.d.ts +0 -10
|
@@ -4,7 +4,7 @@ import { SummarizationChainParams } from 'langchain/chains';
|
|
|
4
4
|
import { BaseLLMParams } from 'langchain/llms/base';
|
|
5
5
|
import { AzureOpenAIInput, OpenAIInput, OpenAI } from 'langchain/llms/openai';
|
|
6
6
|
import { RecursiveCharacterTextSplitter, RecursiveCharacterTextSplitterParams } from 'langchain/text_splitter';
|
|
7
|
-
import { BaseCommandOptions } from '../../types';
|
|
7
|
+
import { BaseCommandOptions } from '../../commands/types';
|
|
8
8
|
/**
|
|
9
9
|
* Get LLM Model Based on Configuration
|
|
10
10
|
* @param fields
|
|
@@ -18,7 +18,7 @@ export declare function getModel(name: string, key: string, fields?: (Partial<Op
|
|
|
18
18
|
* @param options
|
|
19
19
|
* @returns
|
|
20
20
|
*/
|
|
21
|
-
export declare function
|
|
21
|
+
export declare function getApiKeyForModel(name: string, options: BaseCommandOptions): string;
|
|
22
22
|
/**
|
|
23
23
|
* Get Recursive Character Text Splitter
|
|
24
24
|
* @param options
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export declare
|
|
1
|
+
import { FileChangeParserInput } from '../../types';
|
|
2
|
+
export declare function fileChangeParser({ changes, commit, options: { tokenizer, git, model, logger }, }: FileChangeParserInput): Promise<string>;
|
|
@@ -8,5 +8,6 @@ export declare class DiffTreeNode {
|
|
|
8
8
|
addChild(part: string, node: DiffTreeNode): void;
|
|
9
9
|
getChild(part: string): DiffTreeNode | undefined;
|
|
10
10
|
getPath(): string;
|
|
11
|
+
print(indentation?: number): string;
|
|
11
12
|
}
|
|
12
13
|
export declare const createDiffTree: (changes: FileChange[]) => DiffTreeNode;
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import { Logger } from '../utils/logger';
|
|
2
2
|
import { SimpleGit } from 'simple-git';
|
|
3
|
-
|
|
3
|
+
type NoResultInput = {
|
|
4
4
|
git: SimpleGit;
|
|
5
5
|
logger: Logger;
|
|
6
|
-
}
|
|
6
|
+
};
|
|
7
|
+
export declare function noResult({ git, logger }: NoResultInput): Promise<void>;
|
|
8
|
+
export {};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { SimpleGit } from 'simple-git';
|
|
2
2
|
import { FileChange } from '../types';
|
|
3
|
-
export type
|
|
3
|
+
export type GetChangesInput = {
|
|
4
4
|
git: SimpleGit;
|
|
5
5
|
options?: {
|
|
6
6
|
ignoredFiles?: string[];
|
|
@@ -12,4 +12,4 @@ export type GetChangesResult = {
|
|
|
12
12
|
unstaged?: FileChange[];
|
|
13
13
|
untracked?: FileChange[];
|
|
14
14
|
};
|
|
15
|
-
export declare function getChanges({ git, options }:
|
|
15
|
+
export declare function getChanges({ git, options }: GetChangesInput): Promise<GetChangesResult>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { SimpleGit } from 'simple-git';
|
|
2
2
|
import { FileChange } from '../types';
|
|
3
3
|
import { Logger } from '../utils/logger';
|
|
4
|
-
export type
|
|
4
|
+
export type GetChangeByCommitInput = {
|
|
5
5
|
commit: string;
|
|
6
6
|
options: {
|
|
7
7
|
git: SimpleGit;
|
|
@@ -10,4 +10,4 @@ export type GetChangeByCommitArgs = {
|
|
|
10
10
|
ignoredExtensions?: string[];
|
|
11
11
|
};
|
|
12
12
|
};
|
|
13
|
-
export declare function getChangesByCommit({ commit, options: { git, ignoredFiles, ignoredExtensions, }, }:
|
|
13
|
+
export declare function getChangesByCommit({ commit, options: { git, ignoredFiles, ignoredExtensions, }, }: GetChangeByCommitInput): Promise<FileChange[]>;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { SimpleGit } from 'simple-git';
|
|
2
|
+
type GetCommitLogRangeOptions = {
|
|
3
|
+
git: SimpleGit;
|
|
4
|
+
noMerges?: boolean;
|
|
5
|
+
};
|
|
6
|
+
export declare function getCommitLogRange(from: string, to: string, { noMerges, git }: GetCommitLogRangeOptions): Promise<string[]>;
|
|
7
|
+
export {};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { SimpleGit } from 'simple-git';
|
|
2
2
|
import { FileChange } from '../types';
|
|
3
3
|
import { Logger } from '../utils/logger';
|
|
4
|
-
export declare
|
|
4
|
+
export declare function getDiff(nodeFile: FileChange, commit: string, { git, logger, }: {
|
|
5
5
|
git: SimpleGit;
|
|
6
6
|
logger: Logger;
|
|
7
|
-
})
|
|
7
|
+
}): Promise<string>;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { FileChangeStatus } from '../types';
|
|
2
2
|
import { DiffResultBinaryFile, DiffResultTextFile, FileStatusResult } from 'simple-git';
|
|
3
|
-
export declare
|
|
3
|
+
export declare function getStatus(file: FileStatusResult | DiffResultTextFile | DiffResultBinaryFile, location?: 'index' | 'working_dir'): FileChangeStatus;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { DiffResultBinaryFile, DiffResultTextFile, FileStatusResult } from 'simple-git';
|
|
2
2
|
import { FileChange } from '../types';
|
|
3
|
-
export declare
|
|
3
|
+
export declare function getSummaryText(file: FileStatusResult | DiffResultTextFile | DiffResultBinaryFile, change: Partial<FileChange>): string;
|
package/dist/lib/types.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import GPT3Tokenizer from 'gpt3-tokenizer';
|
|
2
1
|
import { getModel } from './langchain/utils';
|
|
3
2
|
import { SimpleGit } from 'simple-git';
|
|
4
3
|
import { Logger } from './utils/logger';
|
|
4
|
+
import { getTokenizer } from './utils/getTokenizer';
|
|
5
5
|
export type FileChangeStatus = 'modified' | 'renamed' | 'added' | 'deleted' | 'untracked' | 'unknown';
|
|
6
6
|
export interface FileChange {
|
|
7
7
|
summary: string;
|
|
@@ -26,11 +26,22 @@ export interface DirectoryDiff {
|
|
|
26
26
|
summary?: string;
|
|
27
27
|
tokenCount: number;
|
|
28
28
|
}
|
|
29
|
-
export interface
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
29
|
+
export interface BaseParserOptions {
|
|
30
|
+
tokenizer: ReturnType<typeof getTokenizer>;
|
|
31
|
+
model: ReturnType<typeof getModel>;
|
|
32
|
+
git: SimpleGit;
|
|
33
|
+
logger: Logger;
|
|
34
|
+
}
|
|
35
|
+
export interface BaseParserInput {
|
|
36
|
+
options: BaseParserOptions;
|
|
37
|
+
}
|
|
38
|
+
export interface FileChangeParserInput extends BaseParserInput {
|
|
39
|
+
changes: FileChange[];
|
|
40
|
+
commit: '--staged' | string;
|
|
41
|
+
}
|
|
42
|
+
export interface CommitLogParserInput extends BaseParserInput {
|
|
43
|
+
range: {
|
|
44
|
+
from: string;
|
|
45
|
+
to: string;
|
|
46
|
+
};
|
|
36
47
|
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { Logger } from '../utils/logger';
|
|
2
|
+
export type GenerateReviewLoopOptions = {
|
|
3
|
+
interactive: boolean;
|
|
4
|
+
logger: Logger;
|
|
5
|
+
prompt?: string;
|
|
6
|
+
openInEditor?: boolean;
|
|
7
|
+
};
|
|
8
|
+
export type GenerateReviewLoopInput<T> = {
|
|
9
|
+
label: string;
|
|
10
|
+
factory: () => Promise<T[]>;
|
|
11
|
+
parser: (changes: T[], commit: string, options: GenerateReviewLoopOptions) => Promise<string>;
|
|
12
|
+
noResult: (options: GenerateReviewLoopOptions) => Promise<void>;
|
|
13
|
+
agent: (context: string, options: GenerateReviewLoopOptions) => Promise<string>;
|
|
14
|
+
options: GenerateReviewLoopOptions;
|
|
15
|
+
};
|
|
16
|
+
export declare function generateAndReviewLoop<T>({ label, factory, parser, noResult, agent, options, }: GenerateReviewLoopInput<T>): Promise<string>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function logResult(result: string): void;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const logSuccess: () => void;
|
package/dist/stats.html
CHANGED
|
@@ -5285,7 +5285,7 @@ var drawChart = (function (exports) {
|
|
|
5285
5285
|
</script>
|
|
5286
5286
|
<script>
|
|
5287
5287
|
/*<!--*/
|
|
5288
|
-
const data = {"version":2,"tree":{"name":"root","children":[{"name":"index.js","children":[{"name":"src","children":[{"name":"lib","children":[{"name":"utils","children":[{"uid":"fad6-78","name":"removeUndefined.ts"},{"uid":"fad6-96","name":"getPathFromFilePath.ts"},{"uid":"fad6-126","name":"getTokenizer.ts"},{"uid":"fad6-128","name":"logger.ts"}]},{"name":"config","children":[{"name":"services","children":[{"uid":"fad6-80","name":"env.ts"},{"uid":"fad6-82","name":"git.ts"},{"uid":"fad6-84","name":"ignore.ts"},{"uid":"fad6-86","name":"project.ts"},{"uid":"fad6-88","name":"xdg.ts"}]},{"uid":"fad6-94","name":"loadConfig.ts"}]},{"name":"langchain","children":[{"name":"prompts","children":[{"uid":"fad6-90","name":"commitDefault.ts"},{"uid":"fad6-92","name":"summarize.ts"}]},{"name":"chains","children":[{"uid":"fad6-98","name":"summarize.ts"},{"uid":"fad6-112","name":"llm.ts"}]},{"uid":"fad6-106","name":"utils.ts"}]},{"name":"parsers","children":[{"name":"default","children":[{"name":"utils","children":[{"uid":"fad6-100","name":"summarizeDiffs.ts"},{"uid":"fad6-102","name":"createDiffTree.ts"},{"uid":"fad6-104","name":"collectDiffs.ts"}]},{"uid":"fad6-110","name":"index.ts"}]},{"uid":"fad6-120","name":"noResult.ts"}]},{"name":"simple-git","children":[{"uid":"fad6-108","name":"getDiff.ts"},{"uid":"fad6-114","name":"getStatus.ts"},{"uid":"fad6-116","name":"getSummaryText.ts"},{"uid":"fad6-118","name":"getChanges.ts"},{"uid":"fad6-122","name":"createCommit.ts"}]},{"uid":"fad6-124","name":"ui.ts"}]},{"name":"commands/commit.ts","uid":"fad6-130"},{"uid":"fad6-132","name":"index.ts"}]}]}],"isRoot":true},"nodeParts":{"fad6-78":{"renderedLength":258,"gzipLength":0,"brotliLength":141,"metaUid":"fad6-77"},"fad6-80":{"renderedLength":990,"gzipLength":0,"brotliLength":352,"metaUid":"fad6-79"},"fad6-82":{"renderedLength":1356,"gzipLength":0,"brotliLength":377,"metaUid":"fad6-81"},"fad6-84":{"renderedLength":927,"gzipLength":0,"brotliLength":271,"metaUid":"fad6-83"},"fad6-86":{"renderedLength":367,"gzipLength":0,"brotliLength":172,"metaUid":"fad6-85"},"fad6-88":{"renderedLength":539,"gzipLength":0,"brotliLength":260,"metaUid":"fad6-87"},"fad6-90":{"renderedLength":1013,"gzipLength":0,"brotliLength":380,"metaUid":"fad6-89"},"fad6-92":{"renderedLength":369,"gzipLength":0,"brotliLength":200,"metaUid":"fad6-91"},"fad6-94":{"renderedLength":1029,"gzipLength":0,"brotliLength":406,"metaUid":"fad6-93"},"fad6-96":{"renderedLength":256,"gzipLength":0,"brotliLength":151,"metaUid":"fad6-95"},"fad6-98":{"renderedLength":442,"gzipLength":0,"brotliLength":201,"metaUid":"fad6-97"},"fad6-100":{"renderedLength":3917,"gzipLength":0,"brotliLength":1170,"metaUid":"fad6-99"},"fad6-102":{"renderedLength":1262,"gzipLength":0,"brotliLength":374,"metaUid":"fad6-101"},"fad6-104":{"renderedLength":1186,"gzipLength":0,"brotliLength":416,"metaUid":"fad6-103"},"fad6-106":{"renderedLength":2442,"gzipLength":0,"brotliLength":704,"metaUid":"fad6-105"},"fad6-108":{"renderedLength":1586,"gzipLength":0,"brotliLength":528,"metaUid":"fad6-107"},"fad6-110":{"renderedLength":1127,"gzipLength":0,"brotliLength":460,"metaUid":"fad6-109"},"fad6-112":{"renderedLength":678,"gzipLength":0,"brotliLength":281,"metaUid":"fad6-111"},"fad6-114":{"renderedLength":1090,"gzipLength":0,"brotliLength":308,"metaUid":"fad6-113"},"fad6-116":{"renderedLength":467,"gzipLength":0,"brotliLength":210,"metaUid":"fad6-115"},"fad6-118":{"renderedLength":2586,"gzipLength":0,"brotliLength":552,"metaUid":"fad6-117"},"fad6-120":{"renderedLength":1269,"gzipLength":0,"brotliLength":410,"metaUid":"fad6-119"},"fad6-122":{"renderedLength":87,"gzipLength":0,"brotliLength":71,"metaUid":"fad6-121"},"fad6-124":{"renderedLength":5671,"gzipLength":0,"brotliLength":1313,"metaUid":"fad6-123"},"fad6-126":{"renderedLength":573,"gzipLength":0,"brotliLength":239,"metaUid":"fad6-125"},"fad6-128":{"renderedLength":1634,"gzipLength":0,"brotliLength":400,"metaUid":"fad6-127"},"fad6-130":{"renderedLength":2413,"gzipLength":0,"brotliLength":743,"metaUid":"fad6-129"},"fad6-132":{"renderedLength":275,"gzipLength":0,"brotliLength":168,"metaUid":"fad6-131"}},"nodeMetas":{"fad6-77":{"id":"/src/lib/utils/removeUndefined.ts","moduleParts":{"index.js":"fad6-78"},"imported":[],"importedBy":[{"uid":"fad6-79"}]},"fad6-79":{"id":"/src/lib/config/services/env.ts","moduleParts":{"index.js":"fad6-80"},"imported":[{"uid":"fad6-77"}],"importedBy":[{"uid":"fad6-93"}]},"fad6-81":{"id":"/src/lib/config/services/git.ts","moduleParts":{"index.js":"fad6-82"},"imported":[{"uid":"fad6-148"},{"uid":"fad6-149"},{"uid":"fad6-146"},{"uid":"fad6-150"}],"importedBy":[{"uid":"fad6-93"}]},"fad6-83":{"id":"/src/lib/config/services/ignore.ts","moduleParts":{"index.js":"fad6-84"},"imported":[{"uid":"fad6-148"}],"importedBy":[{"uid":"fad6-93"}]},"fad6-85":{"id":"/src/lib/config/services/project.ts","moduleParts":{"index.js":"fad6-86"},"imported":[{"uid":"fad6-148"}],"importedBy":[{"uid":"fad6-93"}]},"fad6-87":{"id":"/src/lib/config/services/xdg.ts","moduleParts":{"index.js":"fad6-88"},"imported":[{"uid":"fad6-148"},{"uid":"fad6-146"},{"uid":"fad6-149"}],"importedBy":[{"uid":"fad6-93"}]},"fad6-89":{"id":"/src/lib/langchain/prompts/commitDefault.ts","moduleParts":{"index.js":"fad6-90"},"imported":[{"uid":"fad6-142"}],"importedBy":[{"uid":"fad6-93"},{"uid":"fad6-123"}]},"fad6-91":{"id":"/src/lib/langchain/prompts/summarize.ts","moduleParts":{"index.js":"fad6-92"},"imported":[{"uid":"fad6-142"}],"importedBy":[{"uid":"fad6-93"},{"uid":"fad6-109"}]},"fad6-93":{"id":"/src/lib/config/loadConfig.ts","moduleParts":{"index.js":"fad6-94"},"imported":[{"uid":"fad6-79"},{"uid":"fad6-81"},{"uid":"fad6-83"},{"uid":"fad6-85"},{"uid":"fad6-87"},{"uid":"fad6-89"},{"uid":"fad6-91"}],"importedBy":[{"uid":"fad6-131"},{"uid":"fad6-129"},{"uid":"fad6-117"}]},"fad6-95":{"id":"/src/lib/utils/getPathFromFilePath.ts","moduleParts":{"index.js":"fad6-96"},"imported":[],"importedBy":[{"uid":"fad6-99"}]},"fad6-97":{"id":"/src/lib/langchain/chains/summarize.ts","moduleParts":{"index.js":"fad6-98"},"imported":[{"uid":"fad6-153"}],"importedBy":[{"uid":"fad6-99"}]},"fad6-99":{"id":"/src/lib/parsers/default/utils/summarizeDiffs.ts","moduleParts":{"index.js":"fad6-100"},"imported":[{"uid":"fad6-151"},{"uid":"fad6-95"},{"uid":"fad6-97"}],"importedBy":[{"uid":"fad6-109"}]},"fad6-101":{"id":"/src/lib/parsers/default/utils/createDiffTree.ts","moduleParts":{"index.js":"fad6-102"},"imported":[],"importedBy":[{"uid":"fad6-109"}]},"fad6-103":{"id":"/src/lib/parsers/default/utils/collectDiffs.ts","moduleParts":{"index.js":"fad6-104"},"imported":[],"importedBy":[{"uid":"fad6-109"}]},"fad6-105":{"id":"/src/lib/langchain/utils.ts","moduleParts":{"index.js":"fad6-106"},"imported":[{"uid":"fad6-141"},{"uid":"fad6-142"},{"uid":"fad6-143"},{"uid":"fad6-144"},{"uid":"fad6-145"}],"importedBy":[{"uid":"fad6-129"},{"uid":"fad6-123"},{"uid":"fad6-109"}]},"fad6-107":{"id":"/src/lib/simple-git/getDiff.ts","moduleParts":{"index.js":"fad6-108"},"imported":[{"uid":"fad6-152"}],"importedBy":[{"uid":"fad6-109"}]},"fad6-109":{"id":"/src/lib/parsers/default/index.ts","moduleParts":{"index.js":"fad6-110"},"imported":[{"uid":"fad6-99"},{"uid":"fad6-101"},{"uid":"fad6-103"},{"uid":"fad6-105"},{"uid":"fad6-91"},{"uid":"fad6-107"}],"importedBy":[{"uid":"fad6-123"}]},"fad6-111":{"id":"/src/lib/langchain/chains/llm.ts","moduleParts":{"index.js":"fad6-112"},"imported":[{"uid":"fad6-143"}],"importedBy":[{"uid":"fad6-123"}]},"fad6-113":{"id":"/src/lib/simple-git/getStatus.ts","moduleParts":{"index.js":"fad6-114"},"imported":[],"importedBy":[{"uid":"fad6-117"},{"uid":"fad6-115"}]},"fad6-115":{"id":"/src/lib/simple-git/getSummaryText.ts","moduleParts":{"index.js":"fad6-116"},"imported":[{"uid":"fad6-113"}],"importedBy":[{"uid":"fad6-117"}]},"fad6-117":{"id":"/src/lib/simple-git/getChanges.ts","moduleParts":{"index.js":"fad6-118"},"imported":[{"uid":"fad6-146"},{"uid":"fad6-147"},{"uid":"fad6-113"},{"uid":"fad6-115"},{"uid":"fad6-93"}],"importedBy":[{"uid":"fad6-129"},{"uid":"fad6-119"}]},"fad6-119":{"id":"/src/lib/parsers/noResult.ts","moduleParts":{"index.js":"fad6-120"},"imported":[{"uid":"fad6-117"}],"importedBy":[{"uid":"fad6-123"}]},"fad6-121":{"id":"/src/lib/simple-git/createCommit.ts","moduleParts":{"index.js":"fad6-122"},"imported":[],"importedBy":[{"uid":"fad6-123"}]},"fad6-123":{"id":"/src/lib/ui.ts","moduleParts":{"index.js":"fad6-124"},"imported":[{"uid":"fad6-135"},{"uid":"fad6-136"},{"uid":"fad6-109"},{"uid":"fad6-89"},{"uid":"fad6-105"},{"uid":"fad6-111"},{"uid":"fad6-119"},{"uid":"fad6-121"}],"importedBy":[{"uid":"fad6-129"}]},"fad6-125":{"id":"/src/lib/utils/getTokenizer.ts","moduleParts":{"index.js":"fad6-126"},"imported":[{"uid":"fad6-137"}],"importedBy":[{"uid":"fad6-129"}]},"fad6-127":{"id":"/src/lib/utils/logger.ts","moduleParts":{"index.js":"fad6-128"},"imported":[{"uid":"fad6-135"},{"uid":"fad6-138"},{"uid":"fad6-139"},{"uid":"fad6-140"}],"importedBy":[{"uid":"fad6-129"}]},"fad6-129":{"id":"/src/commands/commit.ts","moduleParts":{"index.js":"fad6-130"},"imported":[{"uid":"fad6-134"},{"uid":"fad6-93"},{"uid":"fad6-123"},{"uid":"fad6-125"},{"uid":"fad6-127"},{"uid":"fad6-105"},{"uid":"fad6-117"}],"importedBy":[{"uid":"fad6-131"}]},"fad6-131":{"id":"/src/index.ts","moduleParts":{"index.js":"fad6-132"},"imported":[{"uid":"fad6-133"},{"uid":"fad6-129"},{"uid":"fad6-93"}],"importedBy":[],"isEntry":true},"fad6-133":{"id":"yargs","moduleParts":{},"imported":[],"importedBy":[{"uid":"fad6-131"}],"isExternal":true},"fad6-134":{"id":"simple-git","moduleParts":{},"imported":[],"importedBy":[{"uid":"fad6-129"}],"isExternal":true},"fad6-135":{"id":"chalk","moduleParts":{},"imported":[],"importedBy":[{"uid":"fad6-123"},{"uid":"fad6-127"}],"isExternal":true},"fad6-136":{"id":"@inquirer/prompts","moduleParts":{},"imported":[],"importedBy":[{"uid":"fad6-123"}],"isExternal":true},"fad6-137":{"id":"gpt3-tokenizer","moduleParts":{},"imported":[],"importedBy":[{"uid":"fad6-125"}],"isExternal":true},"fad6-138":{"id":"ora","moduleParts":{},"imported":[],"importedBy":[{"uid":"fad6-127"}],"isExternal":true},"fad6-139":{"id":"performance-now","moduleParts":{},"imported":[],"importedBy":[{"uid":"fad6-127"}],"isExternal":true},"fad6-140":{"id":"pretty-ms","moduleParts":{},"imported":[],"importedBy":[{"uid":"fad6-127"}],"isExternal":true},"fad6-141":{"id":"langchain/llms/hf","moduleParts":{},"imported":[],"importedBy":[{"uid":"fad6-105"}],"isExternal":true},"fad6-142":{"id":"langchain/prompts","moduleParts":{},"imported":[],"importedBy":[{"uid":"fad6-105"},{"uid":"fad6-89"},{"uid":"fad6-91"}],"isExternal":true},"fad6-143":{"id":"langchain/chains","moduleParts":{},"imported":[],"importedBy":[{"uid":"fad6-105"},{"uid":"fad6-111"}],"isExternal":true},"fad6-144":{"id":"langchain/llms/openai","moduleParts":{},"imported":[],"importedBy":[{"uid":"fad6-105"}],"isExternal":true},"fad6-145":{"id":"langchain/text_splitter","moduleParts":{},"imported":[],"importedBy":[{"uid":"fad6-105"}],"isExternal":true},"fad6-146":{"id":"path","moduleParts":{},"imported":[],"importedBy":[{"uid":"fad6-117"},{"uid":"fad6-81"},{"uid":"fad6-87"}],"isExternal":true},"fad6-147":{"id":"minimatch","moduleParts":{},"imported":[],"importedBy":[{"uid":"fad6-117"}],"isExternal":true},"fad6-148":{"id":"fs","moduleParts":{},"imported":[],"importedBy":[{"uid":"fad6-81"},{"uid":"fad6-83"},{"uid":"fad6-85"},{"uid":"fad6-87"}],"isExternal":true},"fad6-149":{"id":"os","moduleParts":{},"imported":[],"importedBy":[{"uid":"fad6-81"},{"uid":"fad6-87"}],"isExternal":true},"fad6-150":{"id":"ini","moduleParts":{},"imported":[],"importedBy":[{"uid":"fad6-81"}],"isExternal":true},"fad6-151":{"id":"p-queue","moduleParts":{},"imported":[],"importedBy":[{"uid":"fad6-99"}],"isExternal":true},"fad6-152":{"id":"diff","moduleParts":{},"imported":[],"importedBy":[{"uid":"fad6-107"}],"isExternal":true},"fad6-153":{"id":"langchain/document","moduleParts":{},"imported":[],"importedBy":[{"uid":"fad6-97"}],"isExternal":true}},"env":{"rollup":"3.26.3"},"options":{"gzip":false,"brotli":true,"sourcemap":false}};
|
|
5288
|
+
const data = {"version":2,"tree":{"name":"root","children":[{"name":"index.js","children":[{"name":"src","children":[{"name":"lib","children":[{"name":"utils","children":[{"uid":"91d1-106","name":"getPathFromFilePath.ts"},{"uid":"91d1-124","name":"getTokenizer.ts"},{"uid":"91d1-126","name":"logger.ts"},{"uid":"91d1-134","name":"removeUndefined.ts"}]},{"name":"langchain","children":[{"name":"chains/summarize.ts","uid":"91d1-108"},{"uid":"91d1-116","name":"utils.ts"},{"name":"prompts","children":[{"uid":"91d1-118","name":"summarize.ts"},{"uid":"91d1-128","name":"commitDefault.ts"},{"uid":"91d1-178","name":"changelog.ts"}]},{"uid":"91d1-164","name":"executeChain.ts"}]},{"name":"parsers","children":[{"name":"default","children":[{"name":"utils","children":[{"uid":"91d1-110","name":"summarizeDiffs.ts"},{"uid":"91d1-112","name":"createDiffTree.ts"},{"uid":"91d1-114","name":"collectDiffs.ts"}]},{"uid":"91d1-122","name":"index.ts"}]},{"uid":"91d1-150","name":"noResult.ts"}]},{"name":"simple-git","children":[{"uid":"91d1-120","name":"getDiff.ts"},{"uid":"91d1-130","name":"getStatus.ts"},{"uid":"91d1-132","name":"getSummaryText.ts"},{"uid":"91d1-148","name":"getChanges.ts"},{"uid":"91d1-166","name":"createCommit.ts"},{"uid":"91d1-180","name":"getCommitLogRange.ts"}]},{"name":"config","children":[{"name":"services","children":[{"uid":"91d1-136","name":"env.ts"},{"uid":"91d1-138","name":"git.ts"},{"uid":"91d1-140","name":"ignore.ts"},{"uid":"91d1-142","name":"project.ts"},{"uid":"91d1-144","name":"xdg.ts"}]},{"uid":"91d1-146","name":"loadConfig.ts"}]},{"name":"ui","children":[{"uid":"91d1-152","name":"helpers.ts"},{"uid":"91d1-154","name":"logResult.ts"},{"uid":"91d1-156","name":"editResult.ts"},{"uid":"91d1-158","name":"getUserReviewDecision.ts"},{"uid":"91d1-160","name":"editPrompt.ts"},{"uid":"91d1-162","name":"generateAndReviewLoop.ts"},{"uid":"91d1-168","name":"logSuccess.ts"},{"uid":"91d1-170","name":"handleResult.ts"}]}]},{"name":"commands","children":[{"name":"commit","children":[{"uid":"91d1-172","name":"handler.ts"},{"uid":"91d1-174","name":"options.ts"},{"uid":"91d1-176","name":"index.ts"}]},{"name":"changelog","children":[{"uid":"91d1-182","name":"handler.ts"},{"uid":"91d1-184","name":"options.ts"},{"uid":"91d1-186","name":"index.ts"}]}]},{"uid":"91d1-188","name":"index.ts"}]}]}],"isRoot":true},"nodeParts":{"91d1-106":{"renderedLength":256,"gzipLength":0,"brotliLength":151,"metaUid":"91d1-105"},"91d1-108":{"renderedLength":442,"gzipLength":0,"brotliLength":201,"metaUid":"91d1-107"},"91d1-110":{"renderedLength":3917,"gzipLength":0,"brotliLength":1170,"metaUid":"91d1-109"},"91d1-112":{"renderedLength":1861,"gzipLength":0,"brotliLength":515,"metaUid":"91d1-111"},"91d1-114":{"renderedLength":1186,"gzipLength":0,"brotliLength":416,"metaUid":"91d1-113"},"91d1-116":{"renderedLength":2445,"gzipLength":0,"brotliLength":706,"metaUid":"91d1-115"},"91d1-118":{"renderedLength":403,"gzipLength":0,"brotliLength":232,"metaUid":"91d1-117"},"91d1-120":{"renderedLength":2185,"gzipLength":0,"brotliLength":628,"metaUid":"91d1-119"},"91d1-122":{"renderedLength":1153,"gzipLength":0,"brotliLength":469,"metaUid":"91d1-121"},"91d1-124":{"renderedLength":573,"gzipLength":0,"brotliLength":239,"metaUid":"91d1-123"},"91d1-126":{"renderedLength":1634,"gzipLength":0,"brotliLength":400,"metaUid":"91d1-125"},"91d1-128":{"renderedLength":1013,"gzipLength":0,"brotliLength":380,"metaUid":"91d1-127"},"91d1-130":{"renderedLength":1086,"gzipLength":0,"brotliLength":291,"metaUid":"91d1-129"},"91d1-132":{"renderedLength":463,"gzipLength":0,"brotliLength":217,"metaUid":"91d1-131"},"91d1-134":{"renderedLength":258,"gzipLength":0,"brotliLength":141,"metaUid":"91d1-133"},"91d1-136":{"renderedLength":990,"gzipLength":0,"brotliLength":352,"metaUid":"91d1-135"},"91d1-138":{"renderedLength":1356,"gzipLength":0,"brotliLength":377,"metaUid":"91d1-137"},"91d1-140":{"renderedLength":927,"gzipLength":0,"brotliLength":271,"metaUid":"91d1-139"},"91d1-142":{"renderedLength":367,"gzipLength":0,"brotliLength":172,"metaUid":"91d1-141"},"91d1-144":{"renderedLength":539,"gzipLength":0,"brotliLength":260,"metaUid":"91d1-143"},"91d1-146":{"renderedLength":993,"gzipLength":0,"brotliLength":392,"metaUid":"91d1-145"},"91d1-148":{"renderedLength":2586,"gzipLength":0,"brotliLength":552,"metaUid":"91d1-147"},"91d1-150":{"renderedLength":1265,"gzipLength":0,"brotliLength":413,"metaUid":"91d1-149"},"91d1-152":{"renderedLength":147,"gzipLength":0,"brotliLength":109,"metaUid":"91d1-151"},"91d1-154":{"renderedLength":141,"gzipLength":0,"brotliLength":121,"metaUid":"91d1-153"},"91d1-156":{"renderedLength":350,"gzipLength":0,"brotliLength":172,"metaUid":"91d1-155"},"91d1-158":{"renderedLength":1322,"gzipLength":0,"brotliLength":355,"metaUid":"91d1-157"},"91d1-160":{"renderedLength":321,"gzipLength":0,"brotliLength":167,"metaUid":"91d1-159"},"91d1-162":{"renderedLength":2247,"gzipLength":0,"brotliLength":571,"metaUid":"91d1-161"},"91d1-164":{"renderedLength":687,"gzipLength":0,"brotliLength":275,"metaUid":"91d1-163"},"91d1-166":{"renderedLength":87,"gzipLength":0,"brotliLength":71,"metaUid":"91d1-165"},"91d1-168":{"renderedLength":94,"gzipLength":0,"brotliLength":98,"metaUid":"91d1-167"},"91d1-170":{"renderedLength":371,"gzipLength":0,"brotliLength":167,"metaUid":"91d1-169"},"91d1-172":{"renderedLength":1870,"gzipLength":0,"brotliLength":639,"metaUid":"91d1-171"},"91d1-174":{"renderedLength":1347,"gzipLength":0,"brotliLength":379,"metaUid":"91d1-173"},"91d1-176":{"renderedLength":149,"gzipLength":0,"brotliLength":84,"metaUid":"91d1-175"},"91d1-178":{"renderedLength":358,"gzipLength":0,"brotliLength":201,"metaUid":"91d1-177"},"91d1-180":{"renderedLength":667,"gzipLength":0,"brotliLength":304,"metaUid":"91d1-179"},"91d1-182":{"renderedLength":1961,"gzipLength":0,"brotliLength":664,"metaUid":"91d1-181"},"91d1-184":{"renderedLength":1348,"gzipLength":0,"brotliLength":381,"metaUid":"91d1-183"},"91d1-186":{"renderedLength":139,"gzipLength":0,"brotliLength":87,"metaUid":"91d1-185"},"91d1-188":{"renderedLength":478,"gzipLength":0,"brotliLength":197,"metaUid":"91d1-187"}},"nodeMetas":{"91d1-105":{"id":"/src/lib/utils/getPathFromFilePath.ts","moduleParts":{"index.js":"91d1-106"},"imported":[],"importedBy":[{"uid":"91d1-109"}]},"91d1-107":{"id":"/src/lib/langchain/chains/summarize.ts","moduleParts":{"index.js":"91d1-108"},"imported":[{"uid":"91d1-209"}],"importedBy":[{"uid":"91d1-109"}]},"91d1-109":{"id":"/src/lib/parsers/default/utils/summarizeDiffs.ts","moduleParts":{"index.js":"91d1-110"},"imported":[{"uid":"91d1-203"},{"uid":"91d1-105"},{"uid":"91d1-107"}],"importedBy":[{"uid":"91d1-121"}]},"91d1-111":{"id":"/src/lib/parsers/default/utils/createDiffTree.ts","moduleParts":{"index.js":"91d1-112"},"imported":[],"importedBy":[{"uid":"91d1-121"}]},"91d1-113":{"id":"/src/lib/parsers/default/utils/collectDiffs.ts","moduleParts":{"index.js":"91d1-114"},"imported":[],"importedBy":[{"uid":"91d1-121"}]},"91d1-115":{"id":"/src/lib/langchain/utils.ts","moduleParts":{"index.js":"91d1-116"},"imported":[{"uid":"91d1-197"},{"uid":"91d1-196"},{"uid":"91d1-198"},{"uid":"91d1-199"},{"uid":"91d1-200"}],"importedBy":[{"uid":"91d1-171"},{"uid":"91d1-181"},{"uid":"91d1-121"},{"uid":"91d1-159"}]},"91d1-117":{"id":"/src/lib/langchain/prompts/summarize.ts","moduleParts":{"index.js":"91d1-118"},"imported":[{"uid":"91d1-196"}],"importedBy":[{"uid":"91d1-121"},{"uid":"91d1-145"}]},"91d1-119":{"id":"/src/lib/simple-git/getDiff.ts","moduleParts":{"index.js":"91d1-120"},"imported":[{"uid":"91d1-204"}],"importedBy":[{"uid":"91d1-121"}]},"91d1-121":{"id":"/src/lib/parsers/default/index.ts","moduleParts":{"index.js":"91d1-122"},"imported":[{"uid":"91d1-109"},{"uid":"91d1-111"},{"uid":"91d1-113"},{"uid":"91d1-115"},{"uid":"91d1-117"},{"uid":"91d1-119"}],"importedBy":[{"uid":"91d1-171"}]},"91d1-123":{"id":"/src/lib/utils/getTokenizer.ts","moduleParts":{"index.js":"91d1-124"},"imported":[{"uid":"91d1-191"}],"importedBy":[{"uid":"91d1-171"}]},"91d1-125":{"id":"/src/lib/utils/logger.ts","moduleParts":{"index.js":"91d1-126"},"imported":[{"uid":"91d1-192"},{"uid":"91d1-193"},{"uid":"91d1-194"},{"uid":"91d1-195"}],"importedBy":[{"uid":"91d1-171"},{"uid":"91d1-181"}]},"91d1-127":{"id":"/src/lib/langchain/prompts/commitDefault.ts","moduleParts":{"index.js":"91d1-128"},"imported":[{"uid":"91d1-196"}],"importedBy":[{"uid":"91d1-171"},{"uid":"91d1-159"}]},"91d1-129":{"id":"/src/lib/simple-git/getStatus.ts","moduleParts":{"index.js":"91d1-130"},"imported":[],"importedBy":[{"uid":"91d1-147"},{"uid":"91d1-131"}]},"91d1-131":{"id":"/src/lib/simple-git/getSummaryText.ts","moduleParts":{"index.js":"91d1-132"},"imported":[{"uid":"91d1-129"}],"importedBy":[{"uid":"91d1-147"}]},"91d1-133":{"id":"/src/lib/utils/removeUndefined.ts","moduleParts":{"index.js":"91d1-134"},"imported":[],"importedBy":[{"uid":"91d1-135"}]},"91d1-135":{"id":"/src/lib/config/services/env.ts","moduleParts":{"index.js":"91d1-136"},"imported":[{"uid":"91d1-133"}],"importedBy":[{"uid":"91d1-145"}]},"91d1-137":{"id":"/src/lib/config/services/git.ts","moduleParts":{"index.js":"91d1-138"},"imported":[{"uid":"91d1-205"},{"uid":"91d1-206"},{"uid":"91d1-201"},{"uid":"91d1-207"}],"importedBy":[{"uid":"91d1-145"}]},"91d1-139":{"id":"/src/lib/config/services/ignore.ts","moduleParts":{"index.js":"91d1-140"},"imported":[{"uid":"91d1-205"}],"importedBy":[{"uid":"91d1-145"}]},"91d1-141":{"id":"/src/lib/config/services/project.ts","moduleParts":{"index.js":"91d1-142"},"imported":[{"uid":"91d1-205"}],"importedBy":[{"uid":"91d1-145"}]},"91d1-143":{"id":"/src/lib/config/services/xdg.ts","moduleParts":{"index.js":"91d1-144"},"imported":[{"uid":"91d1-205"},{"uid":"91d1-201"},{"uid":"91d1-206"}],"importedBy":[{"uid":"91d1-145"}]},"91d1-145":{"id":"/src/lib/config/loadConfig.ts","moduleParts":{"index.js":"91d1-146"},"imported":[{"uid":"91d1-135"},{"uid":"91d1-137"},{"uid":"91d1-139"},{"uid":"91d1-141"},{"uid":"91d1-143"},{"uid":"91d1-117"}],"importedBy":[{"uid":"91d1-171"},{"uid":"91d1-181"},{"uid":"91d1-147"}]},"91d1-147":{"id":"/src/lib/simple-git/getChanges.ts","moduleParts":{"index.js":"91d1-148"},"imported":[{"uid":"91d1-201"},{"uid":"91d1-202"},{"uid":"91d1-129"},{"uid":"91d1-131"},{"uid":"91d1-145"}],"importedBy":[{"uid":"91d1-171"},{"uid":"91d1-149"}]},"91d1-149":{"id":"/src/lib/parsers/noResult.ts","moduleParts":{"index.js":"91d1-150"},"imported":[{"uid":"91d1-147"}],"importedBy":[{"uid":"91d1-171"},{"uid":"91d1-181"}]},"91d1-151":{"id":"/src/lib/ui/helpers.ts","moduleParts":{"index.js":"91d1-152"},"imported":[{"uid":"91d1-192"}],"importedBy":[{"uid":"91d1-171"},{"uid":"91d1-181"},{"uid":"91d1-153"}]},"91d1-153":{"id":"/src/lib/ui/logResult.ts","moduleParts":{"index.js":"91d1-154"},"imported":[{"uid":"91d1-192"},{"uid":"91d1-151"}],"importedBy":[{"uid":"91d1-161"}]},"91d1-155":{"id":"/src/lib/ui/editResult.ts","moduleParts":{"index.js":"91d1-156"},"imported":[{"uid":"91d1-208"}],"importedBy":[{"uid":"91d1-161"}]},"91d1-157":{"id":"/src/lib/ui/getUserReviewDecision.ts","moduleParts":{"index.js":"91d1-158"},"imported":[{"uid":"91d1-208"}],"importedBy":[{"uid":"91d1-161"}]},"91d1-159":{"id":"/src/lib/ui/editPrompt.ts","moduleParts":{"index.js":"91d1-160"},"imported":[{"uid":"91d1-208"},{"uid":"91d1-127"},{"uid":"91d1-115"}],"importedBy":[{"uid":"91d1-161"}]},"91d1-161":{"id":"/src/lib/ui/generateAndReviewLoop.ts","moduleParts":{"index.js":"91d1-162"},"imported":[{"uid":"91d1-153"},{"uid":"91d1-155"},{"uid":"91d1-157"},{"uid":"91d1-159"}],"importedBy":[{"uid":"91d1-171"},{"uid":"91d1-181"}]},"91d1-163":{"id":"/src/lib/langchain/executeChain.ts","moduleParts":{"index.js":"91d1-164"},"imported":[{"uid":"91d1-198"}],"importedBy":[{"uid":"91d1-171"},{"uid":"91d1-181"}]},"91d1-165":{"id":"/src/lib/simple-git/createCommit.ts","moduleParts":{"index.js":"91d1-166"},"imported":[],"importedBy":[{"uid":"91d1-169"}]},"91d1-167":{"id":"/src/lib/ui/logSuccess.ts","moduleParts":{"index.js":"91d1-168"},"imported":[{"uid":"91d1-192"}],"importedBy":[{"uid":"91d1-169"}]},"91d1-169":{"id":"/src/lib/ui/handleResult.ts","moduleParts":{"index.js":"91d1-170"},"imported":[{"uid":"91d1-165"},{"uid":"91d1-167"}],"importedBy":[{"uid":"91d1-171"},{"uid":"91d1-181"}]},"91d1-171":{"id":"/src/commands/commit/handler.ts","moduleParts":{"index.js":"91d1-172"},"imported":[{"uid":"91d1-121"},{"uid":"91d1-123"},{"uid":"91d1-125"},{"uid":"91d1-127"},{"uid":"91d1-115"},{"uid":"91d1-149"},{"uid":"91d1-147"},{"uid":"91d1-190"},{"uid":"91d1-145"},{"uid":"91d1-151"},{"uid":"91d1-161"},{"uid":"91d1-163"},{"uid":"91d1-169"}],"importedBy":[{"uid":"91d1-175"}]},"91d1-173":{"id":"/src/commands/commit/options.ts","moduleParts":{"index.js":"91d1-174"},"imported":[],"importedBy":[{"uid":"91d1-175"}]},"91d1-175":{"id":"/src/commands/commit/index.ts","moduleParts":{"index.js":"91d1-176"},"imported":[{"uid":"91d1-171"},{"uid":"91d1-173"}],"importedBy":[{"uid":"91d1-187"}]},"91d1-177":{"id":"/src/lib/langchain/prompts/changelog.ts","moduleParts":{"index.js":"91d1-178"},"imported":[{"uid":"91d1-196"}],"importedBy":[{"uid":"91d1-181"}]},"91d1-179":{"id":"/src/lib/simple-git/getCommitLogRange.ts","moduleParts":{"index.js":"91d1-180"},"imported":[],"importedBy":[{"uid":"91d1-181"}]},"91d1-181":{"id":"/src/commands/changelog/handler.ts","moduleParts":{"index.js":"91d1-182"},"imported":[{"uid":"91d1-125"},{"uid":"91d1-115"},{"uid":"91d1-190"},{"uid":"91d1-145"},{"uid":"91d1-151"},{"uid":"91d1-161"},{"uid":"91d1-163"},{"uid":"91d1-149"},{"uid":"91d1-169"},{"uid":"91d1-177"},{"uid":"91d1-179"}],"importedBy":[{"uid":"91d1-185"}]},"91d1-183":{"id":"/src/commands/changelog/options.ts","moduleParts":{"index.js":"91d1-184"},"imported":[],"importedBy":[{"uid":"91d1-185"}]},"91d1-185":{"id":"/src/commands/changelog/index.ts","moduleParts":{"index.js":"91d1-186"},"imported":[{"uid":"91d1-181"},{"uid":"91d1-183"}],"importedBy":[{"uid":"91d1-187"}]},"91d1-187":{"id":"/src/index.ts","moduleParts":{"index.js":"91d1-188"},"imported":[{"uid":"91d1-189"},{"uid":"91d1-175"},{"uid":"91d1-185"}],"importedBy":[],"isEntry":true},"91d1-189":{"id":"yargs","moduleParts":{},"imported":[],"importedBy":[{"uid":"91d1-187"}],"isExternal":true},"91d1-190":{"id":"simple-git","moduleParts":{},"imported":[],"importedBy":[{"uid":"91d1-171"},{"uid":"91d1-181"}],"isExternal":true},"91d1-191":{"id":"gpt3-tokenizer","moduleParts":{},"imported":[],"importedBy":[{"uid":"91d1-123"}],"isExternal":true},"91d1-192":{"id":"chalk","moduleParts":{},"imported":[],"importedBy":[{"uid":"91d1-125"},{"uid":"91d1-151"},{"uid":"91d1-153"},{"uid":"91d1-167"}],"isExternal":true},"91d1-193":{"id":"ora","moduleParts":{},"imported":[],"importedBy":[{"uid":"91d1-125"}],"isExternal":true},"91d1-194":{"id":"performance-now","moduleParts":{},"imported":[],"importedBy":[{"uid":"91d1-125"}],"isExternal":true},"91d1-195":{"id":"pretty-ms","moduleParts":{},"imported":[],"importedBy":[{"uid":"91d1-125"}],"isExternal":true},"91d1-196":{"id":"langchain/prompts","moduleParts":{},"imported":[],"importedBy":[{"uid":"91d1-127"},{"uid":"91d1-115"},{"uid":"91d1-177"},{"uid":"91d1-117"}],"isExternal":true},"91d1-197":{"id":"langchain/llms/hf","moduleParts":{},"imported":[],"importedBy":[{"uid":"91d1-115"}],"isExternal":true},"91d1-198":{"id":"langchain/chains","moduleParts":{},"imported":[],"importedBy":[{"uid":"91d1-115"},{"uid":"91d1-163"}],"isExternal":true},"91d1-199":{"id":"langchain/llms/openai","moduleParts":{},"imported":[],"importedBy":[{"uid":"91d1-115"}],"isExternal":true},"91d1-200":{"id":"langchain/text_splitter","moduleParts":{},"imported":[],"importedBy":[{"uid":"91d1-115"}],"isExternal":true},"91d1-201":{"id":"path","moduleParts":{},"imported":[],"importedBy":[{"uid":"91d1-147"},{"uid":"91d1-137"},{"uid":"91d1-143"}],"isExternal":true},"91d1-202":{"id":"minimatch","moduleParts":{},"imported":[],"importedBy":[{"uid":"91d1-147"}],"isExternal":true},"91d1-203":{"id":"p-queue","moduleParts":{},"imported":[],"importedBy":[{"uid":"91d1-109"}],"isExternal":true},"91d1-204":{"id":"diff","moduleParts":{},"imported":[],"importedBy":[{"uid":"91d1-119"}],"isExternal":true},"91d1-205":{"id":"fs","moduleParts":{},"imported":[],"importedBy":[{"uid":"91d1-137"},{"uid":"91d1-139"},{"uid":"91d1-141"},{"uid":"91d1-143"}],"isExternal":true},"91d1-206":{"id":"os","moduleParts":{},"imported":[],"importedBy":[{"uid":"91d1-137"},{"uid":"91d1-143"}],"isExternal":true},"91d1-207":{"id":"ini","moduleParts":{},"imported":[],"importedBy":[{"uid":"91d1-137"}],"isExternal":true},"91d1-208":{"id":"@inquirer/prompts","moduleParts":{},"imported":[],"importedBy":[{"uid":"91d1-155"},{"uid":"91d1-157"},{"uid":"91d1-159"}],"isExternal":true},"91d1-209":{"id":"langchain/document","moduleParts":{},"imported":[],"importedBy":[{"uid":"91d1-107"}],"isExternal":true}},"env":{"rollup":"3.26.3"},"options":{"gzip":false,"brotli":true,"sourcemap":false}};
|
|
5289
5289
|
|
|
5290
5290
|
const run = () => {
|
|
5291
5291
|
const width = window.innerWidth;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "git-coco",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.4.0",
|
|
4
4
|
"description": "zero-effort git commits with coco.",
|
|
5
5
|
"author": "gfargo <ghfargo@gmail.com>",
|
|
6
6
|
"license": "MIT",
|
|
@@ -52,7 +52,7 @@
|
|
|
52
52
|
"@typescript-eslint/eslint-plugin": "^5.61.0",
|
|
53
53
|
"@typescript-eslint/parser": "^5.61.0",
|
|
54
54
|
"eslint": "^8.42.0",
|
|
55
|
-
"eslint-formatter-pretty": "^
|
|
55
|
+
"eslint-formatter-pretty": "^6.0.0",
|
|
56
56
|
"jest": "^29.5.0",
|
|
57
57
|
"jest-mock": "^29.5.0",
|
|
58
58
|
"release-it": "^16.1.0",
|
|
@@ -72,7 +72,7 @@
|
|
|
72
72
|
"typescript": "^5.1.6"
|
|
73
73
|
},
|
|
74
74
|
"dependencies": {
|
|
75
|
-
"@inquirer/prompts": "^2.
|
|
75
|
+
"@inquirer/prompts": "^3.2.0",
|
|
76
76
|
"chalk": "4.1.2",
|
|
77
77
|
"diff": "^5.1.0",
|
|
78
78
|
"gpt3-tokenizer": "^1.1.5",
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import { Argv, CommandBuilder } from 'yargs';
|
|
2
|
-
import { BaseCommandOptions } from '../types';
|
|
3
|
-
export interface CommitOptions extends BaseCommandOptions {
|
|
4
|
-
interactive: boolean;
|
|
5
|
-
tokenLimit: number;
|
|
6
|
-
prompt: string;
|
|
7
|
-
commit: boolean;
|
|
8
|
-
summarizePrompt: string;
|
|
9
|
-
openInEditor: boolean;
|
|
10
|
-
ignoredFiles: string[];
|
|
11
|
-
ignoredExtensions: string[];
|
|
12
|
-
}
|
|
13
|
-
export declare const command: string[];
|
|
14
|
-
export declare const description = "Generate a commit message based on the diff summary";
|
|
15
|
-
export declare const builder: CommandBuilder<CommitOptions>;
|
|
16
|
-
export declare function handler(argv: Argv<CommitOptions>['argv']): Promise<void>;
|
package/dist/lib/ui.d.ts
DELETED
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { type SimpleGit } from 'simple-git';
|
|
2
|
-
import { getTokenizer } from '../lib/utils/getTokenizer';
|
|
3
|
-
import { Logger } from '../lib/utils/logger';
|
|
4
|
-
import { getModel } from '../lib/langchain/utils';
|
|
5
|
-
import { CommitOptions } from '../commands/commit';
|
|
6
|
-
import { FileChange } from './types';
|
|
7
|
-
export declare const isInteractive: (argv: CommitOptions) => boolean;
|
|
8
|
-
export declare const logCommit: (commit: string) => void;
|
|
9
|
-
export declare const logSuccess: () => void;
|
|
10
|
-
type GenerateReviewLoopOptions = {
|
|
11
|
-
git: SimpleGit;
|
|
12
|
-
interactive: boolean;
|
|
13
|
-
model: ReturnType<typeof getModel>;
|
|
14
|
-
tokenizer: ReturnType<typeof getTokenizer>;
|
|
15
|
-
logger: Logger;
|
|
16
|
-
prompt?: string;
|
|
17
|
-
openInEditor?: boolean;
|
|
18
|
-
};
|
|
19
|
-
export declare const generateCommitMessageAndReviewLoop: (changes: FileChange[], options: GenerateReviewLoopOptions) => Promise<string>;
|
|
20
|
-
export declare const handleResult: (commit: string, { mode, git }: {
|
|
21
|
-
mode: 'interactive' | 'stdout';
|
|
22
|
-
git: SimpleGit;
|
|
23
|
-
}) => Promise<never>;
|
|
24
|
-
export {};
|
package/dist/types.d.ts
DELETED