pyactr

package
v0.13.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 23, 2024 License: MIT Imports: 12 Imported by: 0

Documentation

Overview

Package pyactr provides functions to output the internal actr data structures in Python suitable for running using the pyactr package, and to run those models using Python.

Index

Constants

View Source
const (

	// When a pattern's AnyChunk is true, we use ANY_CHUNK_TYPE for the chunk type
	ANY_CHUNK_TYPE = "any_chunk"
)

Variables

View Source
var Info framework.Info = framework.Info{
	Name:           "pyactr",
	Language:       "python",
	FileExtension:  "py",
	ExecutableName: "python",

	PythonRequiredPackages: []string{"pyactr"},
}

Functions

This section is empty.

Types

type PyACTR

type PyACTR struct {
	framework.Framework
	framework.WriterHelper
	// contains filtered or unexported fields
}

func New

func New(settings *cli.Settings) (p *PyACTR, err error)

New simply creates a new PyACTR instance and sets the tmp path from the context.

func (*PyACTR) GenerateCode added in v0.8.0

func (p *PyACTR) GenerateCode(initialBuffers framework.InitialBuffers) (code []byte, err error)

GenerateCode converts the internal actr.Model to Python code.

func (PyACTR) Info added in v0.5.0

func (PyACTR) Info() *framework.Info

func (PyACTR) Model added in v0.4.0

func (p PyACTR) Model() (model *actr.Model)

func (*PyACTR) Run

func (p *PyACTR) Run(initialBuffers framework.InitialBuffers) (result *framework.RunResult, err error)

func (*PyACTR) SetModel

func (p *PyACTR) SetModel(model *actr.Model) (err error)

func (PyACTR) ValidateModel added in v0.6.0

func (PyACTR) ValidateModel(model *actr.Model) (log *issues.Log)

func (*PyACTR) WriteModel

func (p *PyACTR) WriteModel(path string, initialBuffers framework.InitialBuffers) (outputFileName string, err error)

WriteModel converts the internal actr.Model to Python and writes it to a file.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL