Skip to content

Commit

Permalink
docs(core): adds feature for LLM enhancing
Browse files Browse the repository at this point in the history
  • Loading branch information
juristr committed Feb 17, 2025
1 parent 46cac5b commit baf9e9c
Show file tree
Hide file tree
Showing 6 changed files with 117 additions and 0 deletions.
16 changes: 16 additions & 0 deletions docs/generated/manifests/menus.json
Original file line number Diff line number Diff line change
Expand Up @@ -299,6 +299,14 @@
"children": [],
"disableCollapsible": false
},
{
"name": "Enhance Your LLM",
"path": "/features/enhance-AI",
"id": "enhance-AI",
"isExternal": false,
"children": [],
"disableCollapsible": false
},
{
"name": "Automate Updating Dependencies",
"path": "/features/automate-updating-dependencies",
Expand Down Expand Up @@ -415,6 +423,14 @@
"children": [],
"disableCollapsible": false
},
{
"name": "Enhance Your LLM",
"path": "/features/enhance-AI",
"id": "enhance-AI",
"isExternal": false,
"children": [],
"disableCollapsible": false
},
{
"name": "Automate Updating Dependencies",
"path": "/features/automate-updating-dependencies",
Expand Down
22 changes: 22 additions & 0 deletions docs/generated/manifests/nx.json
Original file line number Diff line number Diff line change
Expand Up @@ -405,6 +405,17 @@
"path": "/features/generate-code",
"tags": ["generate-code"]
},
{
"id": "enhance-AI",
"name": "Enhance Your LLM",
"description": "",
"mediaImage": "",
"file": "shared/features/enhance-AI",
"itemList": [],
"isExternal": false,
"path": "/features/enhance-AI",
"tags": ["AI"]
},
{
"id": "automate-updating-dependencies",
"name": "Automate Updating Dependencies",
Expand Down Expand Up @@ -565,6 +576,17 @@
"path": "/features/generate-code",
"tags": ["generate-code"]
},
"/features/enhance-AI": {
"id": "enhance-AI",
"name": "Enhance Your LLM",
"description": "",
"mediaImage": "",
"file": "shared/features/enhance-AI",
"itemList": [],
"isExternal": false,
"path": "/features/enhance-AI",
"tags": ["AI"]
},
"/features/automate-updating-dependencies": {
"id": "automate-updating-dependencies",
"name": "Automate Updating Dependencies",
Expand Down
9 changes: 9 additions & 0 deletions docs/generated/manifests/tags.json
Original file line number Diff line number Diff line change
Expand Up @@ -373,6 +373,15 @@
"path": "/nx-api/nx/documents/generate"
}
],
"AI": [
{
"description": "",
"file": "shared/features/enhance-AI",
"id": "enhance-AI",
"name": "Enhance Your LLM",
"path": "/features/enhance-AI"
}
],
"automate-updating-dependencies": [
{
"description": "Learn how Nx provides automated update scripts to help you keep your workspace, tooling and framework dependencies up to date.",
Expand Down
6 changes: 6 additions & 0 deletions docs/map.json
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,12 @@
"tags": ["generate-code"],
"file": "shared/features/generate-code"
},
{
"name": "Enhance Your LLM",
"id": "enhance-AI",
"tags": ["AI"],
"file": "shared/features/enhance-AI"
},
{
"name": "Automate Updating Dependencies",
"description": "Learn how Nx provides automated update scripts to help you keep your workspace, tooling and framework dependencies up to date.",
Expand Down
63 changes: 63 additions & 0 deletions docs/shared/features/enhance-AI.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
# Enhance Your LLM

{% youtube src="https://youtu.be/RNilYmJJzdk?si=et_6zWMMxJPa7lp2" title="We Just Made Your LLM Way Smarter!" /%}

Nx Console's LLM enhancement feature makes your AI assistant significantly smarter by providing it with rich metadata about your workspace structure, project relationships, and architectural decisions. While LLMs are powerful tools for boosting development productivity, their effectiveness depends entirely on the context they have access to. Nx Console bridges this gap by:

- Providing **architectural awareness** about your workspace structure and project relationships
- Feeding information about **project ownership and team responsibilities**
- Sharing knowledge about **available tasks** and their configuration
- Including details about **technology stacks** and project types
- Supplying **Nx documentation** context for better assistance

## How It Works

Nx maintains comprehensive metadata about your workspace to power features like [caching](/features/cache-task-results) and [distributed task execution](/features/distribute-task-execution). Nx Console's LLM enhancement taps into this metadata and preprocesses it before providing it to your LLM (currently supporting GitHub Copilot), enabling it to:

- Understand the complete workspace structure, including applications and libraries
- Know how different projects are connected and their dependency relationships
- Recognize project technology stacks and available tasks
- Access information about project ownership and team responsibilities
- Utilize Nx documentation to provide more accurate assistance

This enhanced context allows your LLM to move beyond simple file-level operations to understand your workspace at an architectural level, making it a more effective development partner.

To **enable LLM enhancement in your workspace**:

1. Install or update [Nx Console](/getting-started/editor-setup) in VS Code
2. Ensure you have GitHub Copilot installed and configured
3. Start using Copilot in your Nx workspace by typing `@nx` at the beginning of your prompt - this will automatically provide the enhanced context

{% callout type="note" title="Current Support" %}
LLM enhancement is currently available for VS Code with GitHub Copilot. Support for additional editors and LLM providers is planned for future releases.
{% /callout %}

## Key Benefits

- **Architectural Understanding** - Your LLM gains deep insight into your workspace structure, identifying applications, libraries, and their relationships. It understands project categorization through tags and can make informed suggestions about feature implementation.

- **Team and Ownership Awareness** - Access to project ownership information allows the LLM to identify relevant team members for collaboration and provide guidance on who to consult for specific components.

- **Task and Generator Knowledge** - Enhanced context about workspace tasks and generators enables the LLM to suggest appropriate commands, help set up new projects, and provide guidance on available tasks and their configuration.

Here are some example queries:

Ask your LLM about your workspace structure and get detailed, accurate responses:

![Example of LLM understanding project structure](/blog/images/articles/nx-ai-example-project-data.avif)

Get informed suggestions about where to implement new functionality:

![Example of LLM providing implementation guidance](/blog/images/articles/nx-ai-example-data-access-feature.avif)

### Team Collaboration

Identify relevant team members and ownership information:

![Example of LLM providing ownership information](/blog/images/articles/nx-ai-example-ownership.avif)

### Code Generation

Get assistance with creating new projects using Nx generators:

![Example of LLM helping with code generation](/blog/images/articles/nx-ai-example-generate-code.avif)
1 change: 1 addition & 0 deletions docs/shared/reference/sitemap.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
- [Cache Task Results](/features/cache-task-results)
- [Explore Your Workspace](/features/explore-graph)
- [Generate Code](/features/generate-code)
- [Enhance Your LLM](/features/enhance-AI)
- [Automate Updating Dependencies](/features/automate-updating-dependencies)
- [Enforce Module Boundaries](/features/enforce-module-boundaries)
- [Manage Releases](/features/manage-releases)
Expand Down

0 comments on commit baf9e9c

Please sign in to comment.