Skip to content

Conversation

@pardeike
Copy link
Owner

@pardeike pardeike commented Sep 5, 2025

Summary

  • build llm-pack JSONL from API YAML and markdown articles
  • extend docs workflow to publish llm-pack for HarmonyBot
  • refactor llm-pack generator using pathlib and add executable header

Testing

  • dotnet format --verbosity minimal
  • dotnet test HarmonyTests/HarmonyTests.csproj -c Release -f net9.0

https://chatgpt.com/codex/tasks/task_e_68bae3197f5883299dc9a33af7e46204

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

Codex Review: Here are some suggestions.

Reply with @codex fix comments to fix any unresolved comments.

About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you open a pull request for review, mark a draft as ready, or comment "@codex review". If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex fix this CI failure" or "@codex address that feedback".

Comment on lines 6 to 9
paths:
- 'Documentation/**'
- 'Harmony/**'
- 'scripts/generate_llm_pack.py'

Choose a reason for hiding this comment

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

[P1] Restore docs workflow trigger for Lib.Harmony changes

The docs workflow no longer runs when files under Lib.Harmony/ change. The previous configuration explicitly listed that folder, but the new path filter only covers Harmony/** plus the new generator script. API metadata is produced from Lib.Harmony/bin/Debug/net35/0Harmony.dll, so any API changes applied solely in Lib.Harmony will now bypass the workflow and leave both the documentation and the llm-pack stale. Consider reintroducing Lib.Harmony/** to the trigger list.

Useful? React with 👍 / 👎.

Comment on lines 13 to 28
# API
for path in Path('Documentation/api').rglob('*.yml'):
with path.open(encoding='utf-8') as f:
data = yaml.safe_load(f)
for item in data.get('items', []):
uid = item.get('uid')
kind = (item.get('type') or '').lower()
if not uid or not kind:
continue
summary = item.get('summary')
signature = item.get('syntax', {}).get('content')
remarks = item.get('remarks')
parent = item.get('parent')
doc_page = uid if not parent or parent == 'HarmonyLib' else parent
doc_url = f'https://harmony.pardeike.net/docs/api/{doc_page}.html'
cards.append({

Choose a reason for hiding this comment

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

[P1] Generated API URLs break for generic types

The LLM pack builds API URLs by concatenating the raw uid with .html. DocFX does not emit HTML files with the raw UID for generic or overloaded types (e.g. HarmonyLib.AccessTools.FieldRef<T> becomes HarmonyLib.AccessTools.FieldRef-1.html). For any API element whose UID contains characters like < and >, the resulting doc_url will point to a non-existent page, yielding unusable entries in the JSONL index. Using the href field provided in the YAML or applying the same sanitization as DocFX would keep the links valid.

Useful? React with 👍 / 👎.

@github-actions
Copy link

github-actions bot commented Sep 5, 2025

Test Results

   119 files     119 suites   8m 23s ⏱️
   273 tests    270 ✅   3 💤 0 ❌
30 607 runs  30 076 ✅ 531 💤 0 ❌

Results for commit b8ec066.

@pardeike pardeike merged commit b40c871 into master Sep 5, 2025
6 of 28 checks passed
@pardeike pardeike deleted the codex/add-github-actions-workflow-for-harmonybot branch September 5, 2025 14:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants