Skip to content
Open
Show file tree
Hide file tree
Changes from 32 commits
Commits
Show all changes
45 commits
Select commit Hold shift + click to select a range
d58600d
initial
constewart9 Jun 30, 2025
9396507
external definitions allowed
constewart9 Jun 30, 2025
b5b753d
added inheritance
constewart9 Jul 1, 2025
ff5abb5
feat: inheritance added to relevant definitions
constewart9 Jul 2, 2025
7d68a30
feat: renamed generated output package, included post processing
constewart9 Jul 2, 2025
2c0bde7
feat: generated types integrated in LSR
constewart9 Jul 9, 2025
277801d
feat: removed unncessary flags, cleaned up package.json
constewart9 Jul 11, 2025
7e8065e
fix: more git issues fixed
constewart9 Jul 16, 2025
03cad90
feat: added java definition codegen
constewart9 Jul 21, 2025
2774334
feat: java generation config in openapitools and templates changed dirs
constewart9 Jul 21, 2025
7b6be38
fix: update with newest types
constewart9 Aug 11, 2025
e628678
fix: removing github actions (moving to different branch
constewart9 Aug 11, 2025
08949d5
fix: added readme, updated schema, refactored record.mustace
constewart9 Aug 14, 2025
f89388e
test: finish pre/post generation scripts
constewart9 Aug 14, 2025
0c0c6f4
fix: refactor package.json
constewart9 Aug 14, 2025
9f8907d
test: test to ensure all models are present in output
constewart9 Aug 14, 2025
64697eb
refactor: change output schema name
constewart9 Aug 14, 2025
342cbb4
Merge remote-tracking branch 'upstream/feature/flareProtocolCodeGen' …
constewart9 Aug 14, 2025
8133639
fix: updated README
constewart9 Aug 14, 2025
24aa88b
test: added 10 unit tests for config and basic functionality
constewart9 Aug 15, 2025
e35bf29
fix: replace github action from branch
constewart9 Aug 15, 2025
4997b95
Merge pull request #13 from constewart9/conorstw/types-NEW
constewart9 Aug 15, 2025
1be58e9
test: add tests to github action
constewart9 Aug 15, 2025
2a37667
Merge pull request #14 from constewart9/conorstw/types-NEW
constewart9 Aug 15, 2025
12ba02c
Update package.json
constewart9 Aug 15, 2025
9348eff
Update chatTypes.json to remove empty model
constewart9 Aug 15, 2025
36b8bf4
Update types-codegen-pr.yaml
constewart9 Aug 15, 2025
26e276e
Remove lsp4j addition, moved to generated pom.xml
constewart9 Aug 15, 2025
fd71ee2
Update package.json
constewart9 Aug 15, 2025
0a00ca6
fix: added pom.xml to be generated with java 21
constewart9 Aug 15, 2025
876588b
Merge branch 'main' into conorstw/types-NEW
constewart9 Aug 15, 2025
4e18efc
Merge pull request #15 from constewart9/conorstw/types-NEW
constewart9 Aug 15, 2025
92fb02d
fix: skip PAC URLs in macOS proxy detection (#664)
tsmithsz Aug 18, 2025
1f14063
chore(release): release packages from branch main (#665)
github-actions[bot] Aug 18, 2025
1494b64
Merge branch 'aws:main' into conorstw/types-NEW
constewart9 Aug 19, 2025
d5ef0f3
fix: update the pom.xml generation
constewart9 Aug 18, 2025
0f17f60
fix: split schema into different files
constewart9 Aug 19, 2025
a7c1712
fix: remove extraneous templates and add gson labels to java
constewart9 Aug 19, 2025
252de9c
fix: move external imports to top of file
constewart9 Aug 20, 2025
28ee764
fix: initialize telemetry asynchronously without blocking (#666)
chungjac Aug 21, 2025
37d3cfd
chore: add timeout to ensure error flushes to stdout/err on auth fail…
bryceitoc9 Aug 21, 2025
e0bd323
fix: updated run scripts
constewart9 Aug 22, 2025
719f645
Merge branch 'aws:main' into conorstw/types-NEW
constewart9 Aug 22, 2025
5d7fd5e
fix: make local building more robust
constewart9 Aug 22, 2025
f28bdd1
fix: add openapi-generator-ignore files to clean up output
constewart9 Aug 22, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
69 changes: 69 additions & 0 deletions .github/workflows/types-codegen-pr.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
name: Chat Types PR Validation

on:
pull_request:
branches:
- main
paths:
- 'types/codegen/schema/**'
workflow_dispatch:

jobs:
validate-pr:
name: Validate PR with chatTypes.json changes
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20.x'

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this be updated?

#should we cache: 'npm'

- name: Install root dependencies
working-directory: .
run: npm install

- name: Install codegen dependencies
working-directory: types/codegen
run: npm install

- name: Unit tests
working-directory: types/codegen
run: npm run test:unit

- name: Coalesce schemas
working-directory: types/codegen
run: npm run generate-full-schema

- name: Generate types
working-directory: types/codegen
run: npm run generate:only

- name: Post Process
working-directory: types/codegen
run: npm run post-process

- name: Completeness Test
working-directory: types/codegen
run: npm run test

- name: Build TypeScript
working-directory: types/codegen/generated/typescript
run: |
npm i
npm run build
- name: Setup Java
uses: actions/setup-java@v4
with:
distribution: 'corretto'
java-version: '21'
cache: 'maven'

- name: Build Java with Maven
working-directory: types/codegen/generated/java
run: |
mvn clean compile -Djava.version=21
3 changes: 2 additions & 1 deletion chat-client-ui-types/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
"author": "Amazon Web Services",
"license": "Apache-2.0",
"dependencies": {
"@aws/language-server-runtimes-types": "^0.1.56"
"@aws/language-server-runtimes-types": "^0.1.56",
"@local/language-server-runtimes-generated-types": "file:../types/codegen/generated/typescript"

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you please add a comment here on what the final state should be?

}
}
7 changes: 3 additions & 4 deletions chat-client-ui-types/src/uiContracts.ts
Original file line number Diff line number Diff line change
@@ -1,17 +1,16 @@
import { OPEN_TAB_REQUEST_METHOD, GET_SERIALIZED_CHAT_REQUEST_METHOD } from '@aws/language-server-runtimes-types'
import {
InsertToCursorPositionParams,
ChatOptions,
CodeSelectionType,
ReferenceTrackerInformation,
OPEN_TAB_REQUEST_METHOD,
OpenTabResult,
GET_SERIALIZED_CHAT_REQUEST_METHOD,
GetSerializedChatResult,
ChatPrompt,
OpenFileDialogParams,
DropFilesParams,
} from '@aws/language-server-runtimes-types'
export { InsertToCursorPositionParams } from '@aws/language-server-runtimes-types'
} from '@local/language-server-runtimes-generated-types'
export { InsertToCursorPositionParams } from '@local/language-server-runtimes-generated-types'

export type AuthFollowUpType = 'full-auth' | 're-auth' | 'missing_scopes' | 'use-supported-auth'
export function isValidAuthFollowUpType(value: string): value is AuthFollowUpType {
Expand Down
16 changes: 15 additions & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 3 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
],
"workspaces": [
"types",
"types/codegen/generated/typescript",
"runtimes",
"chat-client-ui-types"
],
Expand All @@ -36,7 +37,8 @@
"test": "npm run test --workspaces --if-present",
"preversion": "npm run test",
"version": "npm run compile && git add -A .",
"watch": "tsc --build --watch"
"watch": "tsc --build --watch",
"gen-comp": "cd ./types/codegen/ && npm run generate && cd ./generated/typescript && npm run build && cd ../../../ && npm run compile"
},
"devDependencies": {
"@commitlint/cli": "^19.8.1",
Expand Down
1 change: 1 addition & 0 deletions runtimes/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
},
"dependencies": {
"@aws/language-server-runtimes-types": "^0.1.56",
"@local/language-server-runtimes-generated-types": "file:../types/codegen/generated/typescript",
"@opentelemetry/api": "^1.9.0",
"@opentelemetry/api-logs": "^0.200.0",
"@opentelemetry/core": "^2.0.0",
Expand Down
80 changes: 40 additions & 40 deletions runtimes/protocol/chat.ts
Original file line number Diff line number Diff line change
@@ -1,18 +1,4 @@
import {
ChatParams,
ChatResult,
EndChatParams,
EndChatResult,
FeedbackParams,
FollowUpClickParams,
InfoLinkClickParams,
InsertToCursorPositionParams,
LinkClickParams,
QuickActionParams,
SourceLinkClickParams,
TabAddParams,
TabChangeParams,
TabRemoveParams,
ProtocolNotificationType,
ProtocolRequestType,
CHAT_REQUEST_METHOD,
Expand All @@ -29,63 +15,77 @@ import {
TAB_CHANGE_NOTIFICATION_METHOD,
TAB_REMOVE_NOTIFICATION_METHOD,
AutoParameterStructuresProtocolRequestType,
OPEN_TAB_REQUEST_METHOD,
CHAT_UPDATE_NOTIFICATION_METHOD,
FILE_CLICK_NOTIFICATION_METHOD,
INLINE_CHAT_REQUEST_METHOD,
CONTEXT_COMMAND_NOTIFICATION_METHOD,
CREATE_PROMPT_NOTIFICATION_METHOD,
INLINE_CHAT_RESULT_NOTIFICATION_METHOD,
PINNED_CONTEXT_NOTIFICATION_METHOD,
LIST_CONVERSATIONS_REQUEST_METHOD,
CONVERSATION_CLICK_REQUEST_METHOD,
GET_SERIALIZED_CHAT_REQUEST_METHOD,
TAB_BAR_ACTION_REQUEST_METHOD,
CHAT_OPTIONS_UPDATE_NOTIFICATION_METHOD,
PROMPT_INPUT_OPTION_CHANGE_METHOD,
BUTTON_CLICK_REQUEST_METHOD,
LIST_MCP_SERVERS_REQUEST_METHOD,
MCP_SERVER_CLICK_REQUEST_METHOD,
RULE_CLICK_REQUEST_METHOD,
LIST_RULES_REQUEST_METHOD,
PINNED_CONTEXT_ADD_NOTIFICATION_METHOD,
PINNED_CONTEXT_REMOVE_NOTIFICATION_METHOD,
ACTIVE_EDITOR_CHANGED_NOTIFICATION_METHOD,
OPEN_FILE_DIALOG_METHOD,
ChatParams,
ChatResult,
EndChatParams,
EndChatResult,
FeedbackParams,
FollowUpClickParams,
InfoLinkClickParams,
InsertToCursorPositionParams,
LinkClickParams,
QuickActionParams,
SourceLinkClickParams,
TabAddParams,
TabChangeParams,
TabRemoveParams,
EncryptedChatParams,
EncryptedQuickActionParams,
QuickActionResult,
OPEN_TAB_REQUEST_METHOD,
OpenTabParams,
OpenTabResult,
CHAT_UPDATE_NOTIFICATION_METHOD,
FILE_CLICK_NOTIFICATION_METHOD,
ChatUpdateParams,
FileClickParams,
INLINE_CHAT_REQUEST_METHOD,
InlineChatParams,
InlineChatResult,
CONTEXT_COMMAND_NOTIFICATION_METHOD,
ContextCommandParams,
CREATE_PROMPT_NOTIFICATION_METHOD,
CreatePromptParams,
INLINE_CHAT_RESULT_NOTIFICATION_METHOD,
PINNED_CONTEXT_NOTIFICATION_METHOD,
InlineChatResultParams,
ListConversationsParams,
ListConversationsResult,
LIST_CONVERSATIONS_REQUEST_METHOD,
ConversationClickParams,
ConversationClickResult,
CONVERSATION_CLICK_REQUEST_METHOD,
GetSerializedChatParams,
GetSerializedChatResult,
GET_SERIALIZED_CHAT_REQUEST_METHOD,
TabBarActionParams,
TabBarActionResult,
TAB_BAR_ACTION_REQUEST_METHOD,
ChatOptionsUpdateParams,
CHAT_OPTIONS_UPDATE_NOTIFICATION_METHOD,
PromptInputOptionChangeParams,
PROMPT_INPUT_OPTION_CHANGE_METHOD,
ButtonClickParams,
ButtonClickResult,
BUTTON_CLICK_REQUEST_METHOD,
ListMcpServersParams,
ListMcpServersResult,
LIST_MCP_SERVERS_REQUEST_METHOD,
ListRulesResult,
RuleClickResult,
PinnedContextParams,
McpServerClickParams,
McpServerClickResult,
MCP_SERVER_CLICK_REQUEST_METHOD,
ListRulesParams,
RuleClickParams,
RULE_CLICK_REQUEST_METHOD,
LIST_RULES_REQUEST_METHOD,
ListRulesResult,
RuleClickResult,
PinnedContextParams,
PINNED_CONTEXT_ADD_NOTIFICATION_METHOD,
PINNED_CONTEXT_REMOVE_NOTIFICATION_METHOD,
ActiveEditorChangedParams,
ACTIVE_EDITOR_CHANGED_NOTIFICATION_METHOD,
OPEN_FILE_DIALOG_METHOD,
OpenFileDialogParams,
OpenFileDialogResult,
LIST_AVAILABLE_MODELS_REQUEST_METHOD,
Expand Down
5 changes: 4 additions & 1 deletion runtimes/protocol/lsp.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,13 @@ import {
RegistrationType,
RequestType,
} from 'vscode-languageserver-protocol'
import { ChatOptions } from '@aws/language-server-runtimes-types'
import { ChatOptions } from '@local/language-server-runtimes-generated-types'
import { LogLevel } from '../runtimes/util/loggingUtil'

//Changed so only METHODS are exported from ./chat
export * from '@aws/language-server-runtimes-types'

export * from '@local/language-server-runtimes-generated-types'
export { TextDocument } from 'vscode-languageserver-textdocument'

// LSP protocol is a core dependency for LSP feature provided by runtimes.
Expand Down
5 changes: 4 additions & 1 deletion types/.gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
LICENSE
NOTICE
SECURITY.md
SECURITY.md
codegen/scripts/**/*
codegen/generated/**/*
codegen/tests/fixtures/**/*
14 changes: 14 additions & 0 deletions types/codegen/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# Generated code
generated/

# Template bank
typescript-template-bank/

# OpenAPI generator metadata
.openapi-generator/

# Node.js dependencies
node_modules/

# Build outputs
dist/
Loading