Skip to content

AI 친화 문서 포맷 생성 — llms.txt 생성 자동화 - #100

Open
RiaOh wants to merge 5 commits into
mainfrom
99-llms-txt
Open

RiaOh wants to merge 5 commits into
mainfrom
99-llms-txt

Conversation

@RiaOh

@RiaOh RiaOh commented Jul 10, 2026 •

Copy link
Copy Markdown
Contributor

배경

LLM이 DaleUI를 쉽게 이해할 수 있도록 www.daleui.com 사이트를 토대로 llmstxt.org 규약에 따른 llms.txt를 자동 생성하는 스크립트를 추가했습니다.
이 파일은 daleui npm 패키지에 포함되어 배포되며, https://www.daleui.com/llms.txt로 서빙되어야 합니다.

수정 전:
daleui 레포 PR 머지 + npm 배포 (llms.txt 포함된 버전) → daleui.com: Dependabot이 daleui 버전 bump PR 생성 → 버전 bump PR 머지 → 재빌드 시 copy 스크립트가 llms.txt 복사 → https://www.daleui.com/llms.txt 서빙

수정 후: daleui.com에서 자체적으로 generate-llms-txt.mts 생성스크립트로 파일 생성

  • llms.txt
  • llms-full.txt : 실제 mdx파일이 있는 문서 전체
  • llms-foundations.txt : 파운데이션
  • llms-components.txt(현재 mdx파일이 없으므로 생성x) : 컴포넌트

해야 할 일

  • llms.txt 파일 등이 gitignore에 추가하여 해당 파일이 github에는 올라와있지 않습니다.
    bun run generate-llms 명령어를 통해 생성해야합니다.

테스팅

현재 아직 배포 전이므로 www.daleui.com/llms.txt 접속 시, 아래와 같은 404페이지가 뜹니다.
image

체크 리스트

  • 코드 리뷰를 요청하기 전에 반드시 CI가 통과하는지 확인해주세요.
  • Cloudflare Preview URL에서 수정한 내용이 의도대로 잘 동작하는지 확인해 주세요.

@RiaOh RiaOh self-assigned this Jul 10, 2026
@RiaOh
RiaOh requested a review from a team as a code owner July 10, 2026 02:20
@github-actions

github-actions Bot commented Jul 10, 2026 •

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Preview URL Updated (UTC)
✅ Ready
View logs
daleui 05ceba9 Commit Preview URL Oct 01 2026, 01:54 PM

@RiaOh RiaOh linked an issue Jul 10, 2026 that may be closed by this pull request
@hyoseong1994

hyoseong1994 commented Jul 10, 2026 •

Copy link
Copy Markdown
Collaborator

이 티켓이 아니고 별도 티켓으로 만드신거같은데 맞을까요?

@RiaOh RiaOh linked an issue Jul 18, 2026 that may be closed by this pull request
4 tasks
@RiaOh RiaOh changed the title LLM 컨텍스트 제공을 위한 llms.txt 페이지 추가 AI 친화 문서 포맷 생성 — llms.txt 및 페이지별 *.md 자동화 Jul 18, 2026
@RiaOh

RiaOh commented Jul 18, 2026

Copy link
Copy Markdown
Contributor Author

@hyoseong1994

https://github.com/DaleStudy/daleui.com/issues/26이 아니고 별도 티켓으로 만드신거같은데 맞을까요?

헛 맞습니다. 기존 티켓이 있는줄 몰랐네요.
별도 티켓은 closed하고, 기존 티켓과 링크해두겠습니다.
알려주셔서 감사합니다!

@hyoseong1994

Copy link
Copy Markdown
Collaborator

@RiaOh 안녕하세요 리아님 기존에 작업하신 내용과 티켓은 비슷하지만 차이가 있습니다. 작업진행이 안되고있는거 같아서 혹시나 싶어 남깁니다.

Comment thread package.json Outdated
"generate-og": "bun scripts/generate-og.mts",
"predev": "bun scripts/sync-blog.mts && bun scripts/generate-og.mts",
"dev": "react-router dev",
"prebuild": "bun scripts/sync-blog.mts && bun scripts/generate-og.mts",

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

prebuild떄 넣는다면 그냥 .gitignore하는 것은 어떤가요?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

@SimYunSup 네, llms.txt파일도 .gitignore에 추가해두었습니다.
gitignore에 추가하는건 생각못했었는데, 알려주셔서 감사합니다 :)

@RiaOh

RiaOh commented Jul 23, 2026

Copy link
Copy Markdown
Contributor Author

@hyoseong1994

@RiaOh 안녕하세요 리아님 기존에 작업하신 내용과 https://github.com/DaleStudy/daleui.com/issues/26은 비슷하지만 차이가 있습니다. 작업진행이 안되고있는거 같아서 혹시나 싶어 남깁니다.

네, 확인해보겠습니다!

@hyoseong1994

Copy link
Copy Markdown
Collaborator

DaleStudy/daleui#1187 와 비슷한 작업으로 예상됩니다.
draft PR 로 변경하시고 1187 작업에 집중하시어 머지하시고 해당 내용을 바탕으로 PR를 재오픈하는걸 권장드립니다.

@RiaOh
RiaOh marked this pull request as draft July 24, 2026 07:41
@RiaOh

RiaOh commented Jul 24, 2026

Copy link
Copy Markdown
Contributor Author

@hyoseong1994

DaleStudy/daleui#1187 와 비슷한 작업으로 예상됩니다.
draft PR 로 변경하시고 1187 작업에 집중하시어 머지하시고 해당 내용을 바탕으로 PR를 재오픈하는걸 권장드립니다.

네, 우선 draft PR로 변경해두었습니다.

@RiaOh

RiaOh commented Jul 24, 2026

Copy link
Copy Markdown
Contributor Author
  • 진행상황: 수정작업이 필요할 듯 하여 draft로 변환하였고, daleui작업을 먼저 진행한 다음 이 daleui.com 작업을 이어서 진행할 예정입니다.

@RiaOh

RiaOh commented Sep 3, 2026

Copy link
Copy Markdown
Contributor Author

@SimYunSup 님, @hyoseong1994 님,
제가 이 작업에 대해서 다시한번 생각을 해봤는데
현재는 daleui 레포에서 skills와 llms.txt를 자동 생성 -> daleui npm 패키지에 'llms.txt' 포함되어 배포 -> daleui.com에서 copy 스크립트가 llms.txt 복사 → https://www.daleui.com/llms.txt 서빙
이런 방식으로 할 예정이었습니다.
근데 생각해보니 llms.txt 파일을 굳이 daleui에서 만들 필요가 있을까 싶어서요.
daleui.com에서도 컴포넌트, 파운데이션쪽 문서가 곧 생기게되면 그걸 토대로 llms.txt를 만들어도 되지 않을까? 싶었습니다.

daleui에서 skills는 여전히 생성하구요.
어떻게 생각하시나요~?

@RiaOh

RiaOh commented Sep 7, 2026

Copy link
Copy Markdown
Contributor Author

수정 예정

  • 이전: daleui 레포에서 llms.txt를 자동 생성 -> daleui npm 패키지에 'llms.txt' 포함되어 배포 -> daleui.com에서 copy 스크립트가 llms.txt 복사 → https://www.daleui.com/llms.txt 서빙
  • 수정방향: daleui.com에서 컴포넌트, 파운데이션 문서를 토대로 llms.txt파일 생성

@hyoseong1994

Copy link
Copy Markdown
Collaborator

수정 예정

  • 이전: daleui 레포에서 llms.txt를 자동 생성 -> daleui npm 패키지에 'llms.txt' 포함되어 배포 -> daleui.com에서 copy 스크립트가 llms.txt 복사 → https://www.daleui.com/llms.txt 서빙
  • 수정방향: daleui.com에서 컴포넌트, 파운데이션 문서를 토대로 llms.txt파일 생성

저는 방향에 대해서 동의합니다.
@SimYunSup 윤섭님은 어떠신가요?

@SimYunSup

Copy link
Copy Markdown
Member

좋습니다!

@RiaOh
RiaOh marked this pull request as ready for review September 24, 2026 08:18
Comment thread scripts/generate-llms-txt.mts Outdated
);

await mkdir(PUBLIC_DIR, { recursive: true });
await writePublic("llms.txt", renderIndex(publishedSets));

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

이슈 #26에는 페이지별 *.md도 포함되어 있는데, 현재는 묶음 파일만 생성됩니다. 프리뷰 /docs/install.md도 Markdown이 아니라 사이트 HTML을 반환하네요. 이번 PR에서 페이지별 파일까지 생성할 예정인가요? 범위를 나누신 거라면 PR 제목과 이슈에도 표시해두면 좋을 것 같습니다.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

아, 네 윤섭님 말씀이 맞습니다! 범위를 나눠야겠네요. 따로 PR 생성하도록 하겠습니다~!

}

function renderIndex(sets: TopicSet[]): string {
const setLinks = [

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

이슈 #26의 llms.txt는 모든 문서 페이지 링크 인덱스인데, 지금은 llms-full.txt와 주제별 묶음 파일만 들어갑니다. 실제 MDX가 있는 문서의 개별 링크도 넣으면 좋을 것 같습니다.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

네, 현재 MDX가 있는 문서의 개별링크도 llms.txt파일에 들어가도록 generate-llms-txt.mts파일을 수정했습니다. 감사합니다.

codes.push(code);
return `\0CODE${codes.length - 1}\0`;
});
const expanded = masked.replace(

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

install.mdx의 <CodeTabs>와 <CodeTab>은 여닫는 태그라 여기서 변환되지 않고 llms-full.txt에도 그대로 남습니다. 탭 이름은 소제목으로 남기고 태그는 걷어내면 좋을 것 같습니다.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

꼼꼼하게 봐주셔서 감사합니다. 반영했습니다. :)

@RiaOh RiaOh changed the title AI 친화 문서 포맷 생성 — llms.txt 및 페이지별 *.md 자동화 AI 친화 문서 포맷 생성 — llms.txt 생성 자동화 Oct 1, 2026
@RiaOh
RiaOh requested a review from SimYunSup October 1, 2026 14:05

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

AI 친화 문서 포맷 생성 — llms.txt 및 페이지별 *.md 자동화 LLM 컨텍스트 제공을 위한 llms.txt 페이지 추가

3 participants