Referenced by16
Labels31

Referencing ideas

IdeaStatusTagsSummaryKatz
anonymous_reference_code_completionAnonymous imports should share the same code completion e. g. ["@/reqlan rq/extension/language/syntax/features-syntax.rq"] should complete the same as `import "@/reqlan rq/extension/language/syntax/features-syntax.rq" as code_completion`. they should share the same code and logic0.060
import_code_completiondoneImport path code completion for `import` / `from` strings ( and shared anonymous paths ). The Rust server is the default engine. The TypeScript provider remains for the node engine. [code_completion] [import_code_completion_explicit_extension] [import_code_completion_path_segments] [import_code_completion_substring_match] [import_code_completion_match_quality] [import_code_completion_ranking] [anonymous_reference_code_completion] [import_code_completion_auto_file_import] [import_code_completion_rendering]0.150
import_code_completion_auto_file_importdoneWhen a code completion for an idea in another file is selected, the import should be automatically added to the current file. This prevents the user from selecting a presented idea, and then having to add the import for the same thing. Uses the same from-import insertion as [import_error] quick fixes; skips the edit when the idea is already imported. [reference_code_completion] [import_code_completion] [import_code_completion_rendering] [import_error]0.095
import_code_completion_explicit_extensionCompletions insert paths with an explicit `.rq` extension. [implicit_file_extension] Hand-written imports may still omit the extension; completion prefers the written form with `.rq`.0.055
import_code_completion_match_qualityRank path candidates by match quality before [import_code_completion_ranking] proximity: an exact substring match outranks a separator-stripped substring match, which outranks an ordered character subsequence match. Within the subsequence tier, a match where every `/` - separated query chunk appears inside a path segment outranks a loose character subsequence. This keeps precise matches above coincidental subsequence matches, so the bounded result list keeps the intended target. [import_code_completion_substring_match] [import_code_completion_ranking]0.070
import_code_completion_path_segmentsIn a folder context, show next path segments ( directories with a trailing `/` ). After `../`, offer `../path/` before nested `../path/file.rq`.0.055
import_code_completion_prefix_aware_rankingA query that starts with an import-root alias ranks that root ' s candidates before all others, before [import_code_completion_ranking] proximity. The typed prefix asserts the root; proximity must not fight that assertion. [import_code_completion_ranking] [import_code_completion_match_quality]0.036
import_code_completion_rankingRank import path completions by directory proximity ( hop count from the completing file ' s directory to the candidate ' s directory ), then directories before files, then path alphabetically. Match-quality tiers from [import_code_completion_match_quality] apply before proximity. Example: typing `../` ranks `../close.rq` before `../../../path.rq`. Emit sortText for that order, and set filterText so the editor does not re-rank by label fuzzy score over proximity.0.078
import_code_completion_renderingdoneReference code completion for ideas from other files shows the relative import path in the completion detail. Same-file ideas omit the path detail. [reference_code_completion] [import_code_completion] [import_code_completion_auto_file_import]0.095
import_code_completion_substring_matchFilter path candidates by search within the path, not only a starts-with prefix. Typing `path` should match `../../parent/path.rq`. Typing `hellopath` should match `../../hello/inbetween/path/file.rq` ( characters matched in order across path segments ).0.064
attribute_code_completion_attribute_keythe attribute key should complete based on endorsed keys and what is present in the index i. e. after the @ symbol at the start of a line, the used attributes should be completed. subsquently, values of the attribute key should be completed based on the values in that attribute key. Values complete for both grammar forms, `@key value` and `@key: value` ( ["../../../../packages/language/src/reqlan.langium"] ). A key already used in the document is filtered out of key completion. Implemented by ["../../../../crates/reqlan-lsp/src/analysis/completion.rs"] and ["../../../../packages/language/src/reqlan-completion-provider.ts"], with site detection in ["../../../../packages/language/src/reqlan-completion-context.ts"]. ["./features-syntax.rq".code_completion]0.046
code_completion_reentry_is_losslessRe-entering a finished path and completing again must keep or deliberately replace the content, never mutate it unpredictably. The candidate equal to the current content ranks first. Candidates whose remainder continues the text after the cursor rank above other candidates of the same match tier. Implemented by ["../../../../crates/reqlan-lsp/src/path_completion.rs"] and ["../../../../packages/language/src/reqlan-path-completion.ts"], with the provider in ["../../../../packages/language/src/reqlan-completion-provider.ts"]. [code_completion_replaces_the_tail] ["../support/features-imports.rq".import_code_completion_ranking]0.036
code_completion_replaces_the_tailCompletion inside an unfinished string or reference name replaces the whole token up to its closing character. Text after the cursor that continues the inserted value is kept, not duplicated; any other tail is consumed. A picked folder keeps a bare file name typed after the cursor: when the inserted value ends with `/` and the tail holds no further `/`, the tail is appended. Applies to anonymous paths ( `["…` ), bare references ( `[…` / `[[…` ), qualified-file idea names ( `["p.rq".…` ), and attribute keys and values ( `@key`, `@key: value` ), matching the import-path behaviour. Matching still uses the typed prefix before the cursor only. Accepting a completion at the end of an unclosed string appends the missing closing delimiter; only when nothing follows the cursor, so in-progress text is never trapped behind a quote. Implemented by ["../../../../crates/reqlan-lsp/src/path_completion.rs"], ["../../../../crates/reqlan-lsp/src/session/completion.rs"], ["../../../../crates/reqlan-lsp/src/analysis/completion.rs"], ["../../../../packages/language/src/reqlan-completion-context.ts"], and ["../../../../packages/language/src/reqlan-completion-provider.ts"]. ["./features-syntax.rq".code_completion] [reference_code_completion_objects] [attribute_code_completion_attribute_key]0.041
completion_site_identifier_charsetCompletion site detection must accept the full grammar identifier charset in every typed prefix: attribute keys, bare references, wikilinks, and qualified-file idea prefixes. The charset is the parser `ID` terminal, `[_a-zA-Z][\w-]*`, which includes the hyphen: ["../../../../packages/language/src/reqlan.langium"]. Site regexes must not encode a narrower charset than the parser `ID` terminal. Implemented by ["../../../../crates/reqlan-lsp/src/path_completion.rs"] and ["../../../../packages/language/src/reqlan-completion-context.ts"]. [reference_code_completion_objects] [attribute_code_completion_attribute_key]0.036
reference_code_completion_objectsdone[reference_code_completion] must offer code completion for all valid reqlan references: - reqlan files ( `.rq` ) - ideas and ideasets in a reqlan file after a quoted path ( `["path".idea]` ) - ideasets and ideaset members ( `[ideaset.member]` ) - code files - folders, including folders that do not contain `.rq` files Import path completion stays limited to `.rq` files. Anonymous file-reference paths share ranking and alias logic with import paths, but they include every file and folder target. Bare dotted references ( `[ideaset.member]`, `[alias.member]` ) complete members in both engines. Members come from open documents and, for closed files, from the ideas index membership edges ( `ideaset_member` ) in the Rust server. The Node engine has no index access, so its bare `set.member` completion stays limited to open documents; `alias.member` reaches closed files in the Rust server through on-demand parse. Reference completion must not fire inside markdown link labels or main-description prose. Scanning every workspace file on each keystroke is too expensive: [reference_code_completion_performance].0.056
reference_code_completion_performancedone[reference_code_completion_objects] must stay interactive on large workspaces. Path completion must not re-walk the filesystem on every keystroke: cache directory listings and reuse them for import and anonymous file-reference completion. Ranking must precompute proximity keys rather than recomputing hop distance per comparator call. The Rust server keeps that ranked list for the listing TTL. A later keystroke filters the list. It does not rebuild relative paths or hop keys. Idea-graph ranking must reuse per-document adjacency across completion requests while document versions are unchanged. Anonymous file-reference completion may omit distant candidates after proximity ranking so the list stays bounded. Implemented by ["../../../../crates/reqlan-lsp/src/path_completion.rs"] ( `PathCompletionCache`, listing cache ), ["../../../../packages/language/src/reqlan-path-completion.ts"] ( `clearPathCompletionCaches`, listing cache, `sortPathCompletionCandidates` ), ["../../../../packages/language/src/reqlan-completion-provider.ts"], and ["../../../../packages/language/src/reqlan-completion-context.ts"]. [reference_code_completion] [reference_code_completion_objects]0.043

Reference labels

"../../../../crates/reqlan-lsp/tests/completion.rs", "../../../../crates/reqlan-lsp/tests/completion.rs:anonymous_file_references_complete_code_files_folders_and_rq_files", "../../../../crates/reqlan-lsp/tests/completion.rs:anonymous_paths_share_import_path_completion", "../../../../crates/reqlan-lsp/tests/completion.rs:appends_the_closing_quote_at_the_end_of_an_unclosed_string", "../../../../crates/reqlan-lsp/tests/completion.rs:cached_path_completion_does_not_re_read_directories", "../../../../crates/reqlan-lsp/tests/completion.rs:completes_attribute_key_replacing_the_tail", "../../../../crates/reqlan-lsp/tests/completion.rs:completes_attribute_value_replacing_the_tail", "../../../../crates/reqlan-lsp/tests/completion.rs:completes_attribute_values_after_the_colon_form", "../../../../crates/reqlan-lsp/tests/completion.rs:completes_attribute_values_after_the_space_form", "../../../../crates/reqlan-lsp/tests/completion.rs:completes_hyphenated_names_after_a_quoted_path", "../../../../crates/reqlan-lsp/tests/completion.rs:completes_hyphenated_reference_names", "../../../../crates/reqlan-lsp/tests/completion.rs:completes_ideas_after_a_quoted_file_path", "../../../../crates/reqlan-lsp/tests/completion.rs:completes_ideaset_members_after_a_bare_dotted_reference", "../../../../crates/reqlan-lsp/tests/completion.rs:completes_ideaset_members_after_a_quoted_path", "../../../../crates/reqlan-lsp/tests/completion.rs:completes_ideaset_members_of_a_closed_file", "../../../../crates/reqlan-lsp/tests/completion.rs:completes_relative_import_paths_with_explicit_rq", "../../../../crates/reqlan-lsp/tests/completion.rs:completing_inside_a_reference_name_replaces_the_tail", "../../../../crates/reqlan-lsp/tests/completion.rs:completing_inside_a_string_replaces_the_tail", "../../../../crates/reqlan-lsp/tests/completion.rs:does_not_complete_inside_markdown_link_labels", "../../../../crates/reqlan-lsp/tests/completion.rs:incomplete_anonymous_alias_paths_match_import_alias_paths", "../../../../crates/reqlan-lsp/tests/completion.rs:matches_import_paths_by_substring", "../../../../crates/reqlan-lsp/tests/completion.rs:prose_lines_do_not_trigger_import_path_completion", "../../../../crates/reqlan-lsp/tests/completion.rs:ranks_alias_root_candidates_first_for_alias_queries", "../../../../crates/reqlan-lsp/tests/completion.rs:ranks_directory_segments_before_nested_files", "../../../../crates/reqlan-lsp/tests/completion.rs:ranks_exact_substring_matches_above_subsequence_matches", "../../../../crates/reqlan-lsp/tests/completion.rs:ranks_import_paths_by_proximity_then_alphabetically", "../../../../crates/reqlan-lsp/tests/completion.rs:ranks_segment_matches_above_subsequence_matches", "../../../../crates/reqlan-lsp/tests/completion.rs:ranks_the_current_value_first_when_reentering_a_path", "../../../../crates/reqlan-lsp/tests/completion.rs:reference_completions_show_source_path_and_auto_import", "../../../../crates/reqlan-lsp/tests/completion.rs:shows_next_path_segments_in_a_folder_context", "../../../../crates/reqlan-lsp/tests/completion.rs:skips_auto_import_when_the_idea_is_already_imported"