Semantic alignment analysis for strategic documents
Rataitosk compares two PDF strategy documents using sentence embeddings (paraphrase-multilingual-MiniLM-L12-v2) to measure semantic alignment across four theory-grounded dimensions. The tool runs completely offline and generates SAMS Scorecards (Semantic Alignment Matrices for Strategy) that combine quantitative scores with qualitative evidence, serving as discussion starters for institutional sensemaking.
Developed as part of a Bachelor's thesis in IT & Digitalization.
1. Thematic Similarity
Overall semantic overlap using distributional semantics (Harris, 1954; Reimers & Gurevych, 2019). Provides baseline assessment of whether documents address similar themes regardless of rhetorical style.
2. Temporal Positioning
How documents construct temporal narratives linking past initiatives, present commitments, and future goals. Grounded in Temporal Work Theory (Kaplan & Orlikowski, 2012) and narrative sensemaking (Weick, 1995).
3. Operational Grounding
Emphasis on present capabilities, existing structures, and ongoing work. Based on exploitation logic (March, 1991) and strategic fit theory (Henderson & Venkatraman, 1993).
4. Transformational Vision
Forward-looking ambition and growth beyond current capabilities. Draws from strategic intent theory (Hamel & Prahalad, 1994) and transformational ambition frameworks (Ahuja & Lampert, 2001).
Rataitosk generates scorecards that function as boundary objects between computational analysis and human judgment. Each scorecard combines:
- Quantitative scores across all four semantic axes
- Qualitative evidence through matched text excerpts
- Interpretive guidance without prescribing conclusions
The tool detects patterns; institutional actors interpret meaning within their organizational context.
- Python 3.9 or newer
- Dependencies listed in
requirements.txt - PDF documents for analysis
If you have Python 3.9+ installed:
python validate_rataitosk.pyThis will:
- Check your Python version
- Download the MiniLM model on first run
- Verify the installation
- Report any missing dependencies
If validation passes, you're ready to use Rataitosk. Otherwise, follow the installation steps below.
Automated Setup (Recommended)
Windows:
install_rataitosk.batLinux/macOS:
bash install_rataitosk.shThe installation scripts will:
- Verify Python version (≥3.9)
- Create an isolated virtual environment
- Install all required dependencies including sentence-transformers
- Download the paraphrase-multilingual-MiniLM-L12-v2 model
- Run validation automatically
Manual Installation
If automated setup fails:
python -m venv venv
source venv/bin/activate # Windows: venv\Scripts\activate
pip install -r requirements.txt
python validate_rataitosk.pyNote: The MiniLM model downloads automatically on first use.
Place two PDF documents in the input/ folder.
python cli/run_rataitosk.pyFind generated SAMS Scorecards in the output/ folder:
- HTML report: Human-readable scorecard with visualizations
rataitosk/
├── input/ # Place your PDF documents here
├── output/ # Generated SAMS Scorecards (HTML)
├── axes/ # Semantic axis implementations
│ ├── thematic_similarity.py
│ ├── temporal_positioning.py
│ ├── operational_grounding.py
│ └── transformational_vision.py
├── cli/ # Command-line interface
├── config/ # Configuration files
├── core/ # Core processing (chunking, embedding, scoring)
├── requirements.txt # Python dependencies
└── README.md
Rataitosk development was guided by two formal design principles:
- Conceptual Grounding – Every metric traces to explicit theoretical constructs
- Data Sovereignty – Institutions maintain complete control over strategic data
These principles emerged through iterative development and are detailed in the thesis (Chapter 7.3).
Rataitosk demonstrates Design Science Research (Hevner et al., 2004; Peffers et al., 2007) applied to semantic alignment analysis in strategic documents. The tool was developed and validated within Norwegian public sector university contexts, addressing the challenge of detecting semantic divergence beneath formal strategic alignment. All processing occurs locally using sentence transformers with the paraphrase-multilingual-MiniLM-L12-v2 model for cross-lingual semantic analysis.
Rataitosk measures semantic patterns in strategic texts. It does not:
- Measure actual organizational alignment or practice
- Assess stakeholder perceptions or institutional culture
- Prescribe strategic decisions or interpretations
- Replace human judgment in strategic planning
The tool provides computational pattern detection as input to institutional dialogue and sensemaking processes.
The tool generates SAMS Scorecards showing semantic alignment across four dimensions:
- Thematic Similarity: 53.83%
- Temporal Positioning: High future-orientation
- Operational Grounding: Strong implementation focus
- Transformational Vision: Moderate change ambition
Full interactive scorecard: See HTML file in /output folder.
Model download fails If the MiniLM model fails to download automatically, check your internet connection and retry. The model is retrieved from Hugging Face on first use.
Module not found errors Ensure you're using the virtual environment Python:
# Windows
.\venv\Scripts\python.exe cli\run_rataitosk.py
# Linux/macOS
./venv/bin/python cli/run_rataitosk.pyFor additional issues: See validate_rataitosk.py output for detailed diagnostics, or open an issue on GitHub.
If you use Rataitosk in your research, please cite:
Aarnseth, T. (2025). Rataitosk: A Method for Assessing Strategic Coherence
via Inter-Document Semantic Alignment. Bachelor's thesis, Høgskolen i Molde.
https://github.com/s0rlie/rataitosk
This project is licensed under the GNU General Public License v3.0. See LICENSE for full terms.
Thomas Aarnseth
Høgskolen i Molde | NTNU
https://www.ntnu.edu/employees/thomas.aarnseth
This work was supervised by Professor Bjørn Jæger at Høgskolen i Molde. Professor Hans Solli-Sæther provided essential guidance on the strategy perspective.