-
Notifications
You must be signed in to change notification settings - Fork 16
Installation
Semantic Synchrony comes in two parts. The "front end" is the application the user interacts with (smsn-mode for Emacs), and the "back end" is the server that manages and persists your knowledge graph.
The SmSn server is a Java application with file-based storage (SQLite + Lucene indices, plus .smsn text files for each note).
git clone https://github.com/synchrony/smsn.git
cd smsn
./gradlew :smsn-server:shadowJarThe result is smsn-server/build/libs/smsn-server-*.jar (approximately 63MB).
Create a smsn.yaml configuration file in the directory where you'll run the server:
# Index directory for SQLite and Lucene indices
indexDirectory: /path/to/index
# Activity log (optional)
activityLog: /path/to/activity.log
# Data sources - each source is a directory of .smsn atom files
sources:
- location: /path/to/public-notes
name: public
code: s
color: 0x00e000
- location: /path/to/personal-notes
name: personal
code: r
color: 0xffc000
- location: /path/to/private-notes
name: private
code: a
color: 0xff0000
# Optional settings
verbose: false
thingNamespace: http://example.org/things/Each source location should be a directory containing .smsn atom files (one per note). These directories can be Git repositories for version control.
Using the helper scripts (run from the directory containing smsn.yaml):
/path/to/smsn/bin/start-server.shOr run directly:
java -Xmx500M -jar /path/to/smsn-server/build/libs/smsn-server-*.jarThe server starts on 0.0.0.0:8182 and accepts WebSocket connections at /smsn. On first startup, it will build the index from your .smsn files (this may take a few minutes for large graphs).
To stop the server:
/path/to/smsn/bin/stop-server.shEmacs 23 or higher is required. Download and install it, then clone smsn-mode:
git clone https://github.com/synchrony/smsn-mode.gitAdd smsn-mode to your Emacs load path. Create a directory under ~/.emacs.d and symlink to smsn-mode:
mkdir ~/.emacs.d/elisp
ln -s /path/to/smsn-mode/lisp ~/.emacs.d/elisp/smsn-mode-lispAdd to your ~/.emacs:
(let ((default-directory "~/.emacs.d/elisp/"))
(normal-top-level-add-subdirs-to-load-path))
(require 'smsn-mode)If the server is not at the default 127.0.0.1:8182:
(defvar smsn-server-host "example.org")
(defvar smsn-server-port 8182)With the server running, start Emacs and type:
M-x smsn
To start, create a root atom with C-c n.
See the howto for everything you need to know to use Semantic Synchrony.
To try SmSn without running your own server, you can connect to the shared graph at fortytwo.net. Just install Emacs and smsn-mode (Steps 4-5 above), then add to your .emacs:
(defvar smsn-server-host "fortytwo.net")To rebuild the index from source files (useful after external edits to .smsn files or to recover from corruption):
- Stop the server
- Delete or move the index directory
- Start the server (it will rebuild automatically)
For historical documentation about the previous TinkerPop/Neo4j-based backend, see Legacy TinkerPop Backend.
Note to SmSn developers: a copy of this wiki page can be found in the graph at :JwGnhoHw23PfCIyp:. However, GitHub is currently the source of truth.