Knowledge & local AI

Daily NBA discussion

Summarize NBA discussions with a route back to the comments.

Interactive study

Explore the example
Project illustration.

Why I’m interested

A discussion has structure: a reply answers a particular comment, and a useful summary needs that context. I wanted an NBA digest that kept the posts and replies behind its conclusions. The interesting problem is condensing the conversation while leaving a clear route back to the source.

Progress

My repository history records a LangChain integration, encoding fixes, and revisions to the retrieval prompts. The Rust example below retrieves excerpts from synthetic comments and links each answer to its source. The next step restores the historical service and repeats that retrieval flow.

Follow the answer back to the discussion

Choose a question about the synthetic basketball thread, then inspect the comment or reply behind the answer.

Choose an example

The answer and its source

The answer is the matching source text, with a link to its place in the discussion. A question without a match returns an explicit no-match result.

Source
Comment 1 — original sample
Answer type
Excerpt

Input

$ sample-doc query "What changed in the defense?"

Result

The team used a zone defense in the fourth quarter. This is a synthetic discussion.

Source: Read the matching passage

The answer and its source

The answer is the matching source text, with a link to its place in the discussion. A question without a match returns an explicit no-match result.

Source
Reply to comment 1 — original sample
Answer type
Excerpt

Input

$ sample-doc query "What happened in the corner?"

Result

The zone left the corner open. The shooter scored twice from that corner.

Source: Read the matching passage

The answer and its source

The answer is the matching source text, with a link to its place in the discussion. A question without a match returns an explicit no-match result.

Source
Comment 3 — original sample
Answer type
Excerpt

Input

$ sample-doc query "What did the center do?"

Result

The center collected four rebounds after halftime.

Source: Read the matching passage

The answer and its source

The answer is the matching source text, with a link to its place in the discussion. A question without a match returns an explicit no-match result.

Input

$ sample-doc query "Who won the championship?"

Result

No source match. This example cannot answer the question.

Rust retrieves excerpts by word overlap and links each answer to its source in the synthetic thread. The historical service uses the LangChain retrieval flow.

Sources and reference notes

Comment 1 — original sample

The team used a zone defense in the fourth quarter. This is a synthetic discussion.

Reply to comment 1 — original sample

The zone left the corner open. The shooter scored twice from that corner.

Comment 3 — original sample

The center collected four rebounds after halftime.

What comes next

Restore the original repository, run the retrieval flow, and compare the answers with their source comments.

Implementation and credits

How does a summary keep the connection between a comment and its reply?

Original synthetic comments form a discussion archive for source-linked retrieval.

Choose a question and follow its answer back to the comment or reply.

Rust builds the sample index and retrieves excerpts by word overlap.

An early personal retrieval experiment, with original synthetic discussion text on this page.

Back to the collection