Step 1 · Keyword Search

Size up the full corpus, choose a keyword that defines your subject rather than your conclusion, cut the corpus down to something a model can read whole, and put it in a project folder.

Step 1 of 5 · Workshop 3:10–3:25
Output: a bounded corpus file in a local project folder

The first decision in any corpus project is what to leave out. A model can read a few hundred documents attentively; it cannot read three hundred thousand. A keyword search is the crudest tool in text analysis, but used at this stage it does exactly one job well: it defines the subject of the study, leaving everything about how that subject is described to be discovered in Step 2.

Section 1The nkmedia corpus

The running example uses the lab's nkmedia database (version 1, July 2026): every article published online by the Korean Central News Agency (KCNA) and the party daily Rodong Sinmun between 1998 and October 2025. Rodong Sinmun articles that KCNA also carried are kept once, under a separate category.

Table 1.1nkmedia v1 at a glance
MeasureValue
Articles310,063
Date range1998-01-01 to 2025-10-31
KCNA (not in Rodong)164,195
Rodong Sinmun137,440
Rodong Sinmun found in KCNA8,428
Characters of body text167.6 million
Median article length336 characters
Articles per year, 2012–20257,500 to 18,100
Each article carries a stable identifier, a short and long title, a category, a date, an author field, the source URL, the raw HTML body and a cleaned text body. The cleaned body is what the model reads.

At 168 million characters the corpus is roughly 40 million tokens: far beyond any model's context window, and beyond anything a person could skim. Even the 2012–2025 portion is about 165,000 articles. Something has to narrow it.

Section 2Why restrict by keyword

There are three ways to shrink a corpus: sample it at random, filter it by metadata (dates, sections, authors), or filter it by content. Random sampling keeps everything in proportion, which is the problem: a topic that occupies 0.3 percent of a newspaper occupies 0.3 percent of the sample. Metadata filters are precise but rarely track a research subject. A content filter does, and a keyword in the title is the most defensible content filter available before you know what you are looking for, because a newspaper's own editors have already judged the article to be about that thing.

The keyword should name the subject of the research, not a hypothesis about it. Searching for 자력갱생 (self-reliance) or 제재 (sanctions) would pre-select the frames the study might later want to measure. Searching for 기업소 (enterprise) selects the organisational unit and says nothing about how it is portrayed. Three further tests, applied in order:

  1. 1Is it small enough to read?The target is a corpus a model can read in a handful of passes and a person can spot-check: a few hundred to low thousands of documents, under about a million characters.
  2. 2Is it diverse enough to be interesting?Check the distribution across years and sources. A keyword that only fires in two years, or only in one newspaper, will give a dataset that cannot speak to change.
  3. 3Does it miss too much?Compare title matches with body matches. If the term appears in the body of ten times as many articles, a title filter is strict; decide whether that strictness is acceptable for the subject.

Section 3Choosing the keyword

Table 1.2 shows the candidates considered for the workshop, with the number of articles each would select. Counts are for the whole corpus (body and title) and for titles in 2012–2025, the Kim Jong Un era, which is the period the running example studies.

Table 1.2Candidate keywords and the corpus each would select
KeywordIn body (all years)In title (all years)In title, 2012–2025Characters, 2012–2025
기업소 enterprise9,8721,298946549,153
공장 factory16,0082,7241,9881,877,698
기업소|공장 either19,5333,8082,7902,327,327
현지지도 on-site guidance7,3521,8521,0242,189,788
지방공업 local industry1,141273269362,508
자력갱생 self-reliance3,892219126115,533
제재 sanctions6,581773497523,172
과학기술 science and technology12,0832,1291,543689,495
Counts are simple substring matches on the cleaned title or body. 기업소 also matches 련합기업소 (complex enterprise). Only the first row was used; the others are shown so you can see what the choice excludes.

The workshop uses 기업소 in the title, 2012–2025. It names an organisational unit, so it is neutral about framing. At 946 articles and 549,000 characters it is readable in full by a model and checkable by a person in an afternoon. It spans every year and both newspapers. And it excludes a lot: 공장 (factory) titles would roughly triple the corpus and 현지지도 (on-site guidance) would pre-select leadership visits, which is one of the things the study wants to measure rather than assume.

Alternatives worth considering

For a study of industrial policy rather than of the enterprise as an institution, 기업소|공장 would be the better subject and the corpus would be about 2,800 articles, still manageable with batching. 지방공업 (local industry) gives a tight 269-article corpus about one policy programme since 2021. Participants bringing their own corpus should apply the same three tests: readable, diverse, and a subject rather than a hypothesis.

Section 4The workshop corpus

The restricted corpus has 946 articles. Table 1.3 shows how they fall across years; the distribution is uneven and that unevenness is itself a finding to carry into Step 2.

Table 1.3Articles with 기업소 in the title, by year and source
Year20122013201420152016201720182019202020212022202320242025
Articles4559353465562326372466126199151
SourceArticlesBody textMedian length
KCNA (not in Rodong)705549,153 characters430 characters
Rodong Sinmun241
2025 covers January to October only. The surge from 2023 coincides with the "20×10 regional development policy" announced in 2024 and the local-industry factory construction campaign that preceded it.

The corpus file keeps the nkmedia columns and adds one: doc_id, a short stable identifier (NKE-0001 to NKE-0946, in date order). Every later file (memos, codebook examples, dataset rows, validation samples) refers to articles by this identifier, so that a claim about an article can always be traced back to its text.

Section 5Download and set up your project folder

The corpus is distributed as an Excel workbook, zipped. Download the zip, create a project folder on your laptop, and unzip it there. Everything you produce in later steps goes in the same folder, so the AI assistant you use in Step 2 can see all of it at once.

A suggested layout. Keep the corpus file unchanged; everything else is derived from it.

Listing 1.1Project folder layout
nk-enterprises/
├── corpus/
│   └── corpus_nk_enterprises_2012-2025.xlsx   # Step 1 – never edited
├── exploration/                                # Step 2 – the model's memos
├── codebook/                                   # Step 3 – codebook_v2.xlsx, codebook.json
├── extraction/                                 # Step 4 – article batches, coded batches, dataset
├── validation/                                 # Step 5 – human samples, reports
└── analysis/                                   # tables and figures
Why Excel, and why zipped

A comma-separated file is the more portable format, but Korean text in CSV is routinely mangled by spreadsheet programs that guess the wrong encoding, and a CSV cannot carry a README. An .xlsx workbook opens correctly everywhere, holds a documentation sheet beside the data, and is read natively by every AI assistant and by pandas. The zip exists for the upload step: web interfaces accept a single zipped file more reliably than a large workbook, and the desktop agents in Step 2 can unzip it themselves.

Check before you share a corpus

Uploading a corpus to an AI service sends it to a third party. The workshop corpus is public newspaper text and may be shared freely. For your own material, confirm that you hold the right to share it, that it contains no personal data you are not authorised to process, and that your institution's rules allow the service you are using. If in doubt, use the instructor-provided corpus for the workshop and ask afterwards.

Terminology

Corpus
The set of documents under study. Here, a table in which each row is one article and one column holds its cleaned text.
Keyword restriction
Selecting documents whose title (or body) contains a term that names the subject of research, so that the corpus becomes small enough to read in full.
doc_id
A short, stable identifier assigned to each document in the restricted corpus. Every later file refers to documents by it.
Project folder
One local folder holding the corpus and every derived file, so that an AI assistant can be given the whole project as context.