Search in sources :

Example 1 with NativeSpeechDispatcher

use of spacegraph.audio.speech.NativeSpeechDispatcher in project narchy by automenta.

the class NARchy method ui.

public static NAR ui() {
    // u.forEach(System.out::println);
    // u.put("boot", new Date().toString());
    // Util.pause(100);
    // u.get("boot", (b)->{
    // System.out.println(b);
    // });
    NAR nar = new DefaultNAR(8, true).exe(new PoolMultiExec(/*WorkerMultiExec*/
    new Focus.AERevaluator(new XoRoShiRo128PlusRandom(1)), 512)).time(new RealTime.CS().durFPS(10f)).get();
    ConjClustering conjClusterB = new ConjClustering(nar, BELIEF, (Task::isInput), 16, 64);
    // ConjClustering conjClusterG = new ConjClustering(nar, GOAL, true, false, 16, 64);
    // auxiliary modules, load in background thread
    nar.runLater(() -> {
        User u = User.the();
        new NARAudio(nar);
        new NARVideo(nar);
        NARHear.readURL(nar);
        {
            NARSpeak s = new NARSpeak(nar);
            s.spoken.on(new NativeSpeechDispatcher()::speak);
        // new NativeSpeechDispatcher(s);
        }
    // //new NoteFS("/tmp/nal", nar);
    // InterNAR i = new InterNAR(nar, 8, 0);
    // i.recv.preAmp(0.1f);
    // i.runFPS(2);
    });
    return nar;
}
Also used : User(jcog.User) NativeSpeechDispatcher(spacegraph.audio.speech.NativeSpeechDispatcher) XoRoShiRo128PlusRandom(jcog.math.random.XoRoShiRo128PlusRandom) PoolMultiExec(nars.exe.PoolMultiExec) ConjClustering(nars.op.stm.ConjClustering) NARVideo(nars.video.NARVideo) NARSpeak(nars.op.language.NARSpeak) RealTime(nars.time.RealTime) NARAudio(nars.audio.NARAudio)

Example 2 with NativeSpeechDispatcher

use of spacegraph.audio.speech.NativeSpeechDispatcher in project narchy by automenta.

the class PoleCart method main.

// private final ScalarConcepts dAngVel;
public static void main(String[] arg) {
    runRT((n) -> {
        try {
            NAgent a = new PoleCart(n);
            a.nar().freqResolution.set(0.02f);
            a.nar().confResolution.set(0.02f);
            NARSpeak s = new NARSpeak(n);
            s.speech.chatty();
            s.spoken.on(new NativeSpeechDispatcher()::speak);
            // n.goalConfidence(0.75f);
            return a;
        } catch (Exception e) {
            e.printStackTrace();
            return null;
        }
    }, 30, 10f);
}
Also used : NativeSpeechDispatcher(spacegraph.audio.speech.NativeSpeechDispatcher) NARSpeak(nars.op.language.NARSpeak) NAgent(nars.NAgent)

Aggregations

NARSpeak (nars.op.language.NARSpeak)2 NativeSpeechDispatcher (spacegraph.audio.speech.NativeSpeechDispatcher)2 User (jcog.User)1 XoRoShiRo128PlusRandom (jcog.math.random.XoRoShiRo128PlusRandom)1 NAgent (nars.NAgent)1 NARAudio (nars.audio.NARAudio)1 PoolMultiExec (nars.exe.PoolMultiExec)1 ConjClustering (nars.op.stm.ConjClustering)1 RealTime (nars.time.RealTime)1 NARVideo (nars.video.NARVideo)1