https://github.com/itsdfish/quantumepisodicmemory.jl
A Julia package for the Generalized Quantum Episodic Memory model
https://github.com/itsdfish/quantumepisodicmemory.jl
human-memory julia julia-language julialang quantum quantum-cognition
Last synced: 9 months ago
JSON representation
A Julia package for the Generalized Quantum Episodic Memory model
- Host: GitHub
- URL: https://github.com/itsdfish/quantumepisodicmemory.jl
- Owner: itsdfish
- License: mit
- Created: 2022-06-14T20:03:43.000Z (about 4 years ago)
- Default Branch: main
- Last Pushed: 2025-08-26T01:23:42.000Z (10 months ago)
- Last Synced: 2025-08-26T03:36:12.232Z (10 months ago)
- Topics: human-memory, julia, julia-language, julialang, quantum, quantum-cognition
- Language: Julia
- Homepage: https://itsdfish.github.io/QuantumEpisodicMemory.jl/dev/
- Size: 3.21 MB
- Stars: 2
- Watchers: 2
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
#

#
[](https://itsdfish.github.io/QuantumEpisodicMemory.jl/dev/) [](https://github.com/itsdfish/QuantumEpisodicMemory.jl/actions/workflows/CI.yml)
This repository constains Julia code for the Generalized Quantum Episodic Memory (GQEM) model of item recognition. In the recognition memory task, subjects study a list of words. In the test phase, three types of words are presented: old words from the study list, new but semantically related words, and new but unrelated words. Subjects are given four sets of instructions
1. gist: respond *yes* to semantically related words (G)
2. verbatim: respond *yes* to old (i.e. studied) words (V)
3. gist + verbatim: respond *yes* to semantically related and old words (G ∪ V)
4. unrelated: respond *yes* to unrelated words (U)
The law of total probability is violated in experiments, such that Pr(G) + Pr(V) > Pr(G ∪ V). Similarly, the judgments are subadditive: Pr(G) + Pr(V) + Pr(U) > 1. These effects emerge in the GQEM because the memory representations are incompatible, meaning they are represented with different, non-orthogonal bases and evaluated sequentially. As a result, LOTP and additivity do not necessarily hold.
# Installation
To install from the REPL, use `]` to switch to the package mode and enter the following:
```julia
add https://github.com/itsdfish/QuantumEpisodicMemory.jl
```
# Example
The following example shows a violation of the total law of probability.
```julia
using QuantumEpisodicMemory
# basis rotation parameters relative to the standard verbatim basis, V
θG = -.12
θU = -1.54
θψO = -.71
θψR = -.86
θψU = 1.26
dist = GQEM(; θG, θU, θψO, θψR, θψU)
preds = compute_preds(dist)
table = to_table(preds)
# violation of LOPT
sum(table[["gist","verbatim"],:], dims=1) - table["gist+verbatim", :]'
```
```julia
1×3 Named Matrix{Float64}
condition ╲ word type │ old related unrelated
──────────────────────┼────────────────────────────────
sum(condition) │ 0.570677 0.419159 0.0797084
```
# References
Trueblood, J. S., & Hemmer, P. (2017). The generalized quantum episodic memory model.
Cognitive Science, 41(8), 2089-2125.