Ting-Wai To
6bdae841d8
test: chunkDocumentWithoutId
2025-07-23 17:44:17 -07:00
Ting-Wai To
24574d3544
test: verify chunkDocument filters out chunks exceeding maxChunkSize
2025-07-22 11:24:59 -07:00
Nate Sesti
dbabee5906
Merge branch 'main' into patch-2
2025-06-20 19:13:30 -07:00
uinstinct
4b4e3e4702
fix misused promises errors in core folder
2025-06-13 23:01:28 +05:30
Jacob
6d6f89fe55
fix: Fix the issue where the chunk index might be duplicated
2025-06-09 11:04:23 +08:00
Nate
184be8f092
npx prettier --check "core/**/*.{js,jsx,ts,tsx,json,css,md}" --ignore-p
...
ath .gitignore --ignore-path .prettierignore --write
2025-05-25 18:34:39 -07:00
Patrick Erichsen
afb6bd0fb5
fix: truncate tagToString to max filename len
2025-05-12 11:28:12 -07:00
Nate
706d8a3b5b
remove code chunker error telemetry
2025-03-18 19:33:43 -07:00
jubilantjerry
8662122b84
Remove path requirement in addTag indexing
2025-02-25 15:15:38 +08:00
jubilantjerry
520498b9b3
Add uniqueness constraint for chunk_tags
2025-02-24 17:06:56 +08:00
Dallin Romney
ddfcefa036
path -> ide part 243243
2024-12-10 20:34:21 -08:00
Dallin Romney
b6b3cceb78
(BROKEN COMMI) path -> uri vscode utils and prompt files cont
2024-12-10 17:28:56 -08:00
Dallin Romney
a88915ec71
merge main
2024-12-10 13:28:41 -08:00
Dallin Romney
0bb131680b
path-uri-context-updates
2024-12-10 13:19:15 -08:00
Dallin Romney
8bfc6f1605
more core tests
2024-12-05 23:34:57 -08:00
Dallin Romney
af5d38e653
move some stuff back
2024-12-04 17:33:58 -08:00
Dallin Romney
a58b0ff7b5
revert fixtures location for less file changes
2024-12-04 17:31:38 -08:00
Dallin Romney
d19411aa0b
revert testdir location for less file changes
2024-12-04 17:30:13 -08:00
Dallin Romney
02f40d04bd
core test cleanup
2024-12-04 17:21:04 -08:00
Test
b5cab4609b
chore: apply eslint to vscode and core
2024-11-11 07:38:52 -08:00
DongjaJ
0f8625faf4
refactor: declare private class properties and initialize
2024-10-18 14:31:24 +09:00
Nate
65925baa5b
don't bother users with non-critical indexing errors
2024-08-29 19:05:22 -07:00
Nate
38cd597431
fall back to basic chunker when parser fails to load
2024-08-29 12:40:20 -07:00
Test
66998efad9
Merge branch 'dev' into pe/repo-map
2024-08-27 14:11:48 -07:00
Test
b7ca371d57
safer indexing
2024-08-27 12:24:17 -07:00
Test
bf426d5e21
feat: get return_type and parameters from snippets
2024-08-26 17:55:39 -07:00
Test
6600501fe7
fix ci again
2024-08-21 22:37:07 -07:00
Patrick Erichsen
5406d0e1a2
test: colocate tests in core
2024-08-16 10:35:40 -07:00
Patrick Erichsen
8cdb68c6d6
update tests
2024-08-15 13:38:15 -07:00
Patrick Erichsen
978f387922
testing: add indexing update tests
2024-08-14 11:30:36 -07:00
Patrick Erichsen
333ba5d6da
Update ChunkCodebaseIndex.ts
2024-08-13 10:30:54 -07:00
Patrick Erichsen
3844208a3b
feat: improve chunking desc on large projects
2024-08-13 10:27:28 -07:00
Rob Leidle
4c4b211aae
Move the bulk insert resolve into the COMMIT callback
...
db.db.serialize(...) guarantees that each statement runs in order. However, the function itself will terminate execution long before all the statements are executed. Therefore, we should only resolve the promise when the last COMMIT transaction has run. In the other cases, there will have been an error and we'll have call reject(err).
This also removed the need for the extra insert that was recently added so it was removed (in fact the extra insert was causing conflict errors).
2024-08-09 16:14:05 -07:00
Rob Leidle
d9efc11193
Turn of chunking for files with more than 1m characters and files lacking extensions
...
This should help with some of the unnecessary work being done in indexing
2024-08-09 13:41:15 -07:00
Nate Sesti
7582aa8240
Indexing tests ( #1979 )
...
* fix missing insertion into lancedb index
* successfully running codebaseindex test
* await
* fix typo
* clean up indexing tests
* expectPlan
2024-08-09 12:54:53 -07:00
Rob Leidle
fad684cb78
Change indexing to operate on batches as returned by getComputeDeleteAddRemove to fix problems ( #1971 )
...
The prior approach, of batching on lists of files as returned by
walkDir(...) broke the assumptions made by
getComputeDeleteAddRemove(...). Instead, call
getComputeDeleteAddRemove() and then batch on its results. This
approach uses a bit more memory but is roughly just as fast.
In addition, made markComplete(...)'s signature return Promise<void> as
it is an async function. Awaiting this async function has made
everything "slow" again because we do not do bulk inserts for
markComplete database rows. However, that can be fixed in a subsequent
commit.
Also disabled WAL mode for SQLite as we do not completely control the
program lifecycle so was noticing a lot of times where indexing resutls
were not checkpointed to disk.
Co-authored-by: Rob Leidle <rleidle@tesla.com>
2024-08-08 15:34:55 -07:00
Nate Sesti
faef4a6ed1
use console.debug
2024-08-08 16:20:52 -04:00
Rob Leidle
4eb5eacfb2
Fix a build breakage on MacOS ( #1955 )
...
Without this change, the following error occurs on MacOS (but not linux):
../core/indexing/chunk/ChunkCodebaseIndex.ts:175:5 - error TS2322: Type 'unknown[]' is not assignable to type 'Chunk[]'.
Type '{}' is missing the following properties from type 'Chunk': digest, filepath, index, content, and 2 more.
175 return chunkLists.flat();
~~~~~~~~~~~~~~~~~~~~~~~~~
Co-authored-by: Rob Leidle <rleidle@tesla.com>
2024-08-07 07:02:31 -07:00
Rob Leidle
dfbc6aabcb
Convert ChunkCodebaseIndexer's sqlite inserts into a single bulk insert to improve performance ( #1943 )
...
This change greatly improves the performance when inserting chunks.
Co-authored-by: Rob Leidle <rleidle@tesla.com>
2024-08-06 16:14:05 -07:00
Rob Leidle
30db947c77
Change ChunkCodebaseIndex to add a tag for known chunks rather than rechunking the file ( #1926 )
...
Note that the prior logic referenced the wrong file contents so it was
likely impacting the accuracy of portions of the index that use the
chunks table.
Co-authored-by: Rob Leidle <rleidle@tesla.com>
2024-08-05 16:39:12 -07:00
Priyash
e93ce84cd5
feat: enable WAL (Write-Ahead Logging) for improved performance and stability ( #1885 )
...
Enable Write-Ahead Logging (WAL) mode for the SQLite database. This change is intended to enhance both the performance and stability of database operations, particularly when handling concurrent transactions and large volumes of data.
2024-08-05 16:38:23 -07:00
Nate Sesti
552f0e0b2d
handle method_declaration in code chunker
2024-08-05 11:35:08 -04:00
Nate Sesti
6a784b6a5a
tweaks to new tokenizing
2024-07-26 15:04:08 -07:00
Rob Leidle
78a4025414
Offload all token counting to worker processes as well as some optimizations to do more token counting in parallel
...
Adding the workerpool logic broke gui as vite does not support __dirname
or path.join(...). To work around this, moved the gui dependency of
stripImages out of countTokens.ts
2024-07-26 13:10:36 -07:00
Patrick Erichsen
3e0fae35a7
feat: include recently + open files in codebase search ( #1833 )
...
* feat: include recently + open files in codebase search
* cleanup
* Update BaseRetrievalPipeline.ts
* add params object to chunkDocument
* Update package-lock.json
2024-07-26 12:40:52 -05:00
Rob Leidle
b961b4e03e
Remove a copy / pasta section that duplicated the work done in ChunkCodebaseIndexer ( #1834 )
...
This cuts the amount of time spent in this section of indexing in half
Co-authored-by: Rob Leidle <rleidle@tesla.com>
2024-07-25 15:35:49 -07:00
Josh Vera
447e1e686d
Refresh index fixes ( #1795 )
...
* Use the resultType given to markComplete
This fixes an issue where if there were multiple result types in itemToAction such as an update with UpdateNewVersion and UpdateOldVersion, only the UpdateOldVersion would be hit (which is a noop) and the UpdateNewVersion would never be fired, causing us to never update the timestamp of the tag_catalog.
* Add a Compute and UpdateLastUpdated to refreshIndex
Removes the ability to insert duplicate rows if we're just computing the result. Instead we replace the existing row instead.
* Don't insert compute tags
They are REPLACEd in markComplete now.
2024-07-22 12:54:11 -07:00
Lukas Kreussel
521669074e
Configurable maxChunkSize for embedding providers ( #1746 )
...
* Add `maxChunkSize` to `EmbeddingsProvider`
* Add `maxChunkSize` to schema
2024-07-16 09:05:19 -07:00
Nate Sesti
74020b1052
Tests for indexing + follow all .gitignore syntax ( #1661 )
...
* cleaner indexing progress updates messages
* chunking tests
* first round of testing for walkDir in .ts
* few more tests
* swap fs with ide
* clean up dead code
* replace traverseDirectory
* fix listFolders
* smoother indexing updates for chunking
* ide pathSetp
* absolute paths test
* fix path sep error with abs paths on windows
* clean up tests
2024-07-03 23:41:43 -07:00
Nate Sesti
04c08c7159
dev ( #1542 )
...
* docs: add docs and schema for "OS" provider (#1536 )
* ignore .env
* fix(gui): ctx rendering w/ renderInlineAs: "" (#1541 )
* ✨ use and cache imports for autocomplete (#1456 )
* ✨ use and cache imports for autocomplete
* fix tsc
* fix codeqwen autocomplete leading space
* add voyage rerank-1
* feat: `--noEmit` for tsc checks in CI (#1559 )
* docs: update CustomContextProvider docs (#1557 )
* add stop tokens to qwen prompt
* update docs to reflect 3.5 sonnet being best
* docs: comment out unused providers (#1561 )
* import Handlebars
* feat: toast notification for config updates (#1560 )
* feat: toast notification for config updates
* feat: only trigger toast on config.json save
* displayRawMarkdown option
* feat: open pane on install (#1564 )
* feat: open pane on activation
* comment out testing code
* update to reflect 16 stop words limit for deepseek
* feat: only trigger config update toast in vscode (#1571 )
* docs(prompt-files): fix typos + clarify (#1575 )
* doc: prompt file typo + clarifications
* fix: add back correct docs
* chore: add telemetry for pageviews (#1576 )
* feat: update onboarding w/ embeddings model (#1570 )
* chore(gui): remove unused pages
* feat: add embeddings step
* feat: update styles
* feat: copy button updates
* fix: correct pull command for embed model
* fix: remove commented code
* fix: remove commented code
* feat: simplify copy btn props
* chore: rename onboarding selection event
* feat: add provider config
* fix: undo msg name
* remove dead code
* fix: invalid mode check
* fix: remove testing logic
* docs(telemetry): add pageviews to tracking list (#1581 )
* Add reranker configuration options to codebase embedding docs (#1584 )
- Introduce reranker concept
- List available reranker options
- Provide configuration instructions
- Update keywords to include "reranker"
* chore: update pr template with screenshots (#1590 )
* Refactor ConfirmationDialog to use SecondaryButton for cancel action (#1586 )
* Added instructions for running docs server locally (#1578 )
- Added NPM script method
- Added VS Code task method
- Update contributing guidelines
* Update branch policy (#1577 )
- Change PR target to `dev` branch
- Update `CONTRIBUTING.md` instructions
* Consolidate example configurations into the main configuration guide (#1579 )
- Moved examples to configuration.md
- Deleted the separate examples.md file
- Updated sidebar order and links
- Improved readability and structure in configuration.md
* fix: fullscreen gui retains context when hidden, fixed fullscreen focusing (#1582 )
* Update completionProvider.ts (warning tab-autocomplete models) (#1566 )
* feat: enhanced IndexingProgressBar with blinking dot feature
- Integrated BlinkingDot component
- Added STATUS_COLORS for various states
- Replaced CircleDiv with BlinkingDot in UI
- Updated status messages and layout
* small UI tweaks
* feat(gui): enhance ModelCard, ModelProviderTag, and Toggle components (#1595 )
- add styling and adjustments to ModelCard
- update ModelProviderTag font size
- remove box shadow from Toggle component
- tweak icon styles in ModelCard
- improve alignment and spacing
* media query
* feat: add best experience onboarding
* fix: file rename
* stop movement on button hover by keeping same border thickness
* fix mistake in setting cursor: pointer
* fix when free trial option is shown
* Support Node.js versions below 20 for streaming response handling (#1591 )
- Add fallback for Node < 20
- Implement toAsyncIterable for streaming
- Use TextDecoder for manual decoding
- Maintain existing streaming for Node 20+
* small fixes
* feat: add free trial card to onboarding (#1600 )
* feat: add free trial card to onboarding
* add import
* fix hasPassedFTL
* fix /edit cancellation from UI
* feat: add `applyCodeBlock` experimental prop (#1601 )
* feat: add new model styling improvements (#1609 )
* feat: add new model styling improvements
* better gap size
* feat: update bug_report.yml (#1610 )
* chore: update bug_report.yml
* typo fix
* feat: add labels to "Add docs" dialog (#1612 )
* feat: add labels to "Add docs" dialog
* remove autofocus
* don't double load config
* small fixes
* speed up directory traversal, and use correct native path module
* option not to show config update toast
* merge air-gapped and recommended setup pages
* chore: add telemetry for full screen toggle (#1618 )
* Fix headings in codebase-embeddings.md (#1617 )
* mention jetbrains
* docs: update changie (#1619 )
* feat: updated changie config
* hide toc and autogenerate
* Update changelog.mdx
* link to deeper explanation of embeddings models
* ensure target="_blank" for all links in sidebar
* fix gif links in intellij README.md
* don't require rust in dependency installation
* chore: fix padding on gh button (#1620 )
* chore: adjust button padding
* Update tasks.json
* escape colons in diff path
* smoother lancedb indexing reporting
* smooth progress updates for indexing
* fix tsc err
* rerank-lite-1
---------
Co-authored-by: Patrick Erichsen <patrick.a.erichsen@gmail.com>
Co-authored-by: Priyash <38959321+priyashpatil@users.noreply.github.com>
Co-authored-by: Jonah Wagner <jonahwagner231@gmail.com>
Co-authored-by: YohannZe <99359799+YohannZe@users.noreply.github.com>
Co-authored-by: Dan Dascalescu <ddascalescu+github@gmail.com>
2024-06-28 16:21:36 -07:00