npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@sschepis/sixthsense

v1.0.2

Published

A library for generating symbolic representations based on environmental entropy.

Downloads

6

Readme

Sixth Sense

npm version

A TypeScript library for generating symbolic representations based on environmental entropy, primarily derived from user interactions like mouse movements and keystrokes.

Overview

Resonator Core captures subtle timing variations in user input to generate an "entropy snapshot". This snapshot is then used to:

  1. Compute EDM (Entropy Deviation Metric): Measures the deviation from a baseline entropy level, indicating potential shifts in user attention or system state.
  2. Evolve a Wavefunction (Ψ): Simulates a quantum-like state based on the current entropy characteristics.
  3. Collapse HQE (Hyperdimensional Quantum Encoding): Probabilistically selects a symbolic representation (based on I Ching hexagrams, Tarot, Runes, Hebrew letters) from the evolved wavefunction, influenced by the entropy snapshot.

The library also provides a SymbolicEventBus for emitting events related to entropy generation, attention levels, and wavefunction collapse.

Installation

npm install @sschepis/sixthsense
# or
yarn add @sschepis/sixthsense

Basic Usage

import { tickResonator, ResonatorBus } from 'resonator-core';

// Listen for collapse events
ResonatorBus.on('resonator:collapse', {
  handler: (event) => {
    console.log('Wavefunction Collapsed:', event.symbol.code);
    console.log('Symbol Details:', event.symbol);
    console.log('Resonance Score:', event.resonance.score);
  }
});

// Listen for attention events
ResonatorBus.on('resonator:attention', {
  handler: (event) => {
    console.log('Attention Level:', event.level, 'Coherent:', event.coherent);
  }
});

// --- Triggering the Resonator ---

// Option 1: On an interval
setInterval(() => {
  const collapseResult = tickResonator();
  // You can use the direct result if needed, though the bus is often preferred
  // console.log('Direct Collapse Result:', collapseResult);
}, 1000); // Example: tick every second

// Option 2: Hooked to requestAnimationFrame (for smoother browser integration)
function animationLoop() {
  tickResonator();
  requestAnimationFrame(animationLoop);
}
// requestAnimationFrame(animationLoop); // Uncomment to start loop

// Option 3: Triggered by specific UI events
// Make sure the event listeners in lib/entropy.ts are active (they run by default in browser)
document.body.addEventListener('click', (event) => {
  console.log('Ticking resonator on click...');
  tickResonator(event); // Pass the event context (optional)
});

Core Concepts

  • Entropy (lib/entropy.ts): Captures timing deltas from mousemove and keydown events. Requires a browser-like environment with window.performance and event listeners.
  • EDM (lib/edm.ts): Calculates attention/coherence based on entropy deviation.
  • Wavefunction (lib/wavefunction.ts): A mathematical model representing potential states, influenced by time and entropy delta.
  • Encoder (lib/encoder.ts): Collapses the wavefunction into a specific symbol based on probabilities derived from the wavefunction's state and entropy bits. Includes mappings for I Ching, Tarot, Runes, and Hebrew letters.
  • Event Bus (lib/bus.ts): Allows different parts of an application to subscribe to resonator events without tight coupling.

Environment

This library is primarily designed for browser environments where window.addEventListener and performance.now() are available for entropy generation. Limited functionality might be possible in Node.js if entropy data is provided externally.

License

ISC (See package.json)