DEV Community

Cover image for How We Deliver a Bilingual Research Digest with Python, ChatGPT, and Slack
Haruki Niwa
Haruki Niwa

Posted on AI-assisted

How We Deliver a Bilingual Research Digest with Python, ChatGPT, and Slack

Our neuroscience lab shares papers in English and Japanese on Slack through Research Literature Insights. From Monday through Thursday, the digest recommends up to one paper a day. On Friday, it compares papers from the week.

How the pieces fit together

Python collects paper records from OpenAlex and Europe PMC into Google Drive. ChatGPT Work reads the candidates and writes reports to Drive. An Ubuntu service fetches each report and sends English and Japanese posts to Slack.

A scheduled Python job on Ubuntu saves candidates and search logs to discovery/YYYY-MM-DD.json on Google Drive. ChatGPT Work reads the inventory alongside the lab’s research profile, recommendation history and journal club records, then writes a report with source references back to Drive. A systemd user service fetches the report with rclone, validates it and posts both language versions through a Slack incoming webhook. SQLite tracks each post separately.

Report When analysis starts (Japan time) What Work produces
Daily Paper Spotlight Monday–Thursday, 10 a.m. Up to one paper, with its findings, limitations and a reason to read it.
Weekly Research Review Friday, 10 a.m. A comparison drawing on the daily reports and the broader Monday–Thursday candidate pool. Delivery requires at least two sources and a supported theme or comparison.

Turning six research areas into searches

Our original four keyword queries covered fMRI decoding but had no search for aesthetic preference. For our lab, even a study based entirely on ratings of paintings could be relevant. ChatGPT proposed six search areas based on the lab’s published research plans and projects. We adopted them on November 17. The profile gives current priorities precedence over past publications and sets no quota for any area. Chikazoe Laboratory research projects

Research area Keyword queries
Emotion and cognition emotion cognition
Sensory and taste representations taste perception
Aesthetic preference and individual taste aesthetic preference
Mental and neural representations brain representation, fMRI decoding
fMRI foundation models and connectivity methods fMRI foundation model, functional connectivity
Individual traits and psychiatric or neurological conditions brain individual differences, psychiatric neuroimaging

Python runs these nine queries against both OpenAlex and Europe PMC. It also searches three journals (NeuroImage, Human Brain Mapping and Nature Neuroscience), follows related works and citations to two seed papers, and searches adjacent topics. Four longer semantic queries capture questions such as whether a person’s preferences generalize across paintings, landscapes and faces.

How Python chose the 50 abstracts

For the November 19 daily report, we ran the selection workflow on live research records with Slack delivery disabled. Python retrieved 475 records with publication dates from October 21 through November 19. Merging duplicates left 445. To qualify, a record needed an abstract and identifiers that cleared checks against lab holdings and previous recommendations and posts. The title or abstract also had to pass a term check.

  • Its title contained at least one configured neuroscience or research-theme term. Adding terms such as taste and preference let behavioral studies qualify on their titles.
  • If the title had no match, the abstract contained at least two distinct configured neuroscience terms.

323 records qualified. Among the 122 exclusions, 80 failed only the term check, 29 lacked only an abstract, 11 failed both checks and two had already been recommended and posted.

November 19 daily report. Python collected 475 records, merged them into 445 and kept 323. It passed 50 with abstracts and logged the remaining 273. Work examined nine items closely, including material outside the 50, and recommended one.

Python ranked eligible records in bands A–D according to which neuroscience, method and topic terms appeared together. Within each band, topic terms earned 12 points in the title and two in the abstract. A title containing fMRI could reach band A on that word alone because it appeared in both the neuroscience and method lists.

All 50 abstracts passed to Work came from band A. Another 69 A-band records fell outside the cap. For all 273 eligible records outside the 50, the screening log kept the title, identifier, rank and reason for omission. Work could follow an identifier to the public source. Across the search as a whole, 22 queries returned fewer records than their reported hit counts. The inventory’s complete flag records whether the planned searches succeeded. We don’t know what fraction of relevant papers these searches retrieved.

How Work chose what the lab should read

To recommend a paper, Work must verify at least its abstract against the original source. It judges the strength of the evidence separately from the reason to read the paper. Does the result address a lab question, offer a usable method or suggest a study worth running? A replication or negative result can qualify. If the evidence or relevance is too weak, the daily report can contain zero recommendations.

Work examined nine items for the November 19 report, consulting two full texts, six abstracts and one dataset description. The aesthetic-preference dataset came from outside the 50. Its unversioned record ranked 202nd, and Work followed it to the depositor’s description. Dataset on Mendeley Data

The report recommended Wu and Turrigiano’s mouse taste-learning study, which Python had ranked 16th. The authors tracked responses in the gustatory cortex as mice learned an aversion to saccharin and as that aversion faded. Our lab had distinguished basic tastes from patterns of human insular activity. Work selected the paper because it suggested tracking the same taste before and after learning changes its value. Taste-learning study on eLife

Delivering both languages reliably

For a new daily report, Work writes and reads back a draft, then signals readiness. Ubuntu checks the dated files, validates the saved JSON and tracks eligible Slack posts by language.

Work and Ubuntu run on separate schedules. To keep Ubuntu from reading a half-written daily report, Work saves draft-YYYY-MM-DD, reads it back, then creates ready-YYYY-MM-DD. When creating a production report, Ubuntu looks for exactly one draft and one ready marker with the expected filenames for that date. It checks the date, status="ready" and test_only=false in the draft, then saves the JSON to Drive and compares the downloaded bytes with the validated draft. For the weekly report, Work validates the JSON before saving and checks the exported document afterward.

If English reaches Slack and the Japanese request times out, resending both messages could post English twice. SQLite tracks a separate delivery state for each language. The sender marks a post as sent after Slack returns HTTP 200 with an ok body. On retry, it skips acknowledged posts. If delivery is uncertain, the operator checks the channel before retrying. The paper enters the posting history once both languages are confirmed. Slack’s incoming webhook documentation


AI disclosure: This article documents my own technical setup and results. An LLM was used to help draft, organize, and edit the English text. I remain responsible for its technical accuracy.

Top comments (1)

Collapse
 
alexshev profile image
Alex Shev •

The pipeline becomes more trustworthy when translation is treated as a versioned transformation, not just an output. I’d retain the source item ID, source language, model or glossary version, and reviewer status with every digest entry. That makes corrections traceable without losing the speed benefits of automation.