67 lines
1.7 KiB
Go
67 lines
1.7 KiB
Go
package workflows
|
|
|
|
import (
|
|
"context"
|
|
"errors"
|
|
)
|
|
|
|
var ErrNotImplemented = errors.New("workflow runner not implemented")
|
|
|
|
type DiagnosticInput struct {
|
|
UserID string
|
|
Track string
|
|
TargetRole string
|
|
Stack []string
|
|
}
|
|
|
|
type Runner interface {
|
|
DiagnoseJobSeeker(context.Context, DiagnosticInput) (DiagnosticResult, error)
|
|
GradeInterviewAnswer(context.Context, GradeAnswerInput) (GradedAnswer, error)
|
|
ExtractLearningMemory(context.Context, GradedAnswer) (MemoryUpdateCandidate, error)
|
|
SelectNextChallenge(context.Context, NextChallengeInput) (NextChallenge, error)
|
|
UpdateReadinessMap(context.Context, ReadinessUpdateInput) (ReadinessUpdate, error)
|
|
}
|
|
|
|
type GradeAnswerInput struct {
|
|
UserID string
|
|
QuestionID string
|
|
AnswerID string
|
|
AnswerText string
|
|
}
|
|
|
|
type NextChallengeInput struct {
|
|
UserID string
|
|
Track string
|
|
}
|
|
|
|
type ReadinessUpdateInput struct {
|
|
UserID string
|
|
Track string
|
|
}
|
|
|
|
type StubRunner struct{}
|
|
|
|
func NewStubRunner() StubRunner {
|
|
return StubRunner{}
|
|
}
|
|
|
|
func (StubRunner) DiagnoseJobSeeker(context.Context, DiagnosticInput) (DiagnosticResult, error) {
|
|
return DiagnosticResult{}, ErrNotImplemented
|
|
}
|
|
|
|
func (StubRunner) GradeInterviewAnswer(context.Context, GradeAnswerInput) (GradedAnswer, error) {
|
|
return GradedAnswer{}, ErrNotImplemented
|
|
}
|
|
|
|
func (StubRunner) ExtractLearningMemory(context.Context, GradedAnswer) (MemoryUpdateCandidate, error) {
|
|
return MemoryUpdateCandidate{}, ErrNotImplemented
|
|
}
|
|
|
|
func (StubRunner) SelectNextChallenge(context.Context, NextChallengeInput) (NextChallenge, error) {
|
|
return NextChallenge{}, ErrNotImplemented
|
|
}
|
|
|
|
func (StubRunner) UpdateReadinessMap(context.Context, ReadinessUpdateInput) (ReadinessUpdate, error) {
|
|
return ReadinessUpdate{}, ErrNotImplemented
|
|
}
|