lingapp-revisao-redacao
v1.0.11
Published
Mongoose model for managing essay reviews
Maintainers
Readme
@lingapp/revisao-redacao
A Mongoose model for managing essay reviews in the LingApp system. This package provides a structured way to handle essay reviews with annotations, comments, and scoring.
Features
- Full TypeScript support
- Mongoose model with proper typing
- Support for PDF annotations
- Competency-based review system
- Status tracking for reviews
- File attachments support (review PDF and audio feedback)
Installation
npm install @lingapp/revisao-redacao
# or
yarn add @lingapp/revisao-redacaoUsage
import { RevisaoRedacao, RevisaoRedacaoInterface, StatusRevisaoRedacao } from '@lingapp/revisao-redacao';
// Create a new review
const review = new RevisaoRedacao({
tema: temaId,
redacao: redacaoId,
status: StatusRevisaoRedacao.EmAvaliacao,
revisor: revisorId,
revisao: [
{
competencia: competenciaId,
nota: 8.5,
comentarios: [
{
id: '1',
linha: 5,
comentario: 'Good argument structure',
tags: [{ _id: 'tag1', name: 'Structure' }]
}
],
anotacoes: [] // PDF annotations
}
],
arquivoRevisao: fileId,
audio: audioFileId // Optional audio feedback
});
// Save the review
await review.save();Types
The package exports the following types:
RevisaoRedacaoInterface- Main review interfaceRevisaoInterface- Individual competency review interfaceAnotacoesInterface- Comment interfaceStatusRevisaoRedacao- Review status enumTagInterface- Tag interface for commentsCompetenciaInterface- Competency interface- And other related interfaces
Schema Structure
The model includes:
- Review status tracking
- Competency-based scoring
- Line-specific comments with tags
- PDF annotations support
- File attachments (review PDF and audio)
- Timestamps for creation and updates
Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
License
MIT
