Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/remrama/thococo
Thought contents and constraints
https://github.com/remrama/thococo
Last synced: 27 days ago
JSON representation
Thought contents and constraints
- Host: GitHub
- URL: https://github.com/remrama/thococo
- Owner: remrama
- Created: 2022-11-13T03:07:18.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2024-12-14T19:56:30.000Z (about 2 months ago)
- Last Synced: 2024-12-14T20:27:59.329Z (about 2 months ago)
- Language: Python
- Homepage:
- Size: 58.6 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# thococo
A research project testing how **tho**ught **co**ntents are **co**nstrained by cognitive control. The question is largely driven by the Dynamic Framework of Thought proposed in [Christoff et al., 2016, _Nat Rev Neurosci_](https://doi.org/10.1038/nrn.2016.113).
- `environment.yml` can be used to construct the Python environment
- `config.json` has general parameter options that apply to multiple scripts
- `utils.py` has general functions that are useful to multiple scripts
- `gutenberg-generate_sourcedata.py` was used to extract relevant files from the [Standardized Project Gutenberg Corpus](https://github.com/pgcorpus/gutenberg)```shell
# Download spaCy model
python -m spacy download en_core_web_lg# Generate data directory structure
python setup_directories.py #=> derivatives/ & derivatives/zips/# Convert raw data to standardized text files
python source2txt.py --corpus gutenberg #=> zips/gutenberg.zip
python source2txt.py --corpus dreamviews #=> zips/dreamviews.zip
python source2txt.py --corpus thoughtpings #=> zips/thoughtpings.zip# Get semantic incoherence scores
python coherence.py --corpus gutenberg #=> corp-gutenberg_scores.tsv
python coherence.py --corpus dreamviews #=> corp-dreamviews_scores.tsv
python coherence.py --corpus thoughtpings #=> corp-thoughtpings_scores.tsv# Verify semantic incoherence measure
python gutenberg-plot.py #=> corp-gutenberg_scores.png/pdf# Run binned comparison within each dataset
python twoway.py --corpus dreamviews #=> corp-dreamviews_2way.tsv/png/pdf
python twoway.py --corpus thoughtpings #=> corp-thoughtpings_2way.tsv/png/pdf# Correlate coherence with self-reported mind-wandering in the thoughtpings dataset.
python correlation.py #=> corp-thoughtpings_corr.tsv/png/pdf
```