Skip to content

Commit

Permalink
Merge branch 'hotfix/0.9.4'
Browse files Browse the repository at this point in the history
  • Loading branch information
JeltevanBoheemen committed Jun 11, 2024
2 parents 42670b0 + 3f694b4 commit d5cdbba
Show file tree
Hide file tree
Showing 18 changed files with 47 additions and 34 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@ All notable changes (beginning at version 0.2.0) to this project will be documen
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [0.9.4] - 2024-06-11
### Added
- Added outgoing links to homepage

## [0.9.3] - 2024-06-04
### Changed
- Upgraded SASTADEV to 0.2.2
Expand Down
4 changes: 2 additions & 2 deletions CITATION.cff
Original file line number Diff line number Diff line change
Expand Up @@ -41,5 +41,5 @@ abstract: >-
transcripts, to aid clinical linguists and research into
language development and language disorders.
license: BSD-3-Clause
version: 0.9.3
date-released: '2024-01-31'
version: 0.9.4
date-released: '2024-06-11'
11 changes: 0 additions & 11 deletions backend/analysis/convert/tests/convert_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,14 +77,3 @@ def test_quotemarks(quotemarks):
expected = (quotemarks[-1], None)
for line in quotemarks:
assert replace_quotation_marks(line) == expected


def test_chat_replacements(testfiles_dir, tarsp_category):
'''Test if CHAT input handles replacements correctly'''
fn = op.join(testfiles_dir, 'sample_1.cha')
doc = ChatDocument.from_chatfile(fn, tarsp_category)
line = doc.lines[1]

assert line.text == 'Jan fietst niet meer+...'
assert line.tiers['xano'].text == '0|NAAM1|Jan'
assert line.tiers['xpct'].text == '20|…|+...'
2 changes: 1 addition & 1 deletion backend/annotations/writers/saf_chat.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ def enrich_chat(transcript: Transcript,

# construct a mapping of uttno to uttid
# because uttid is unknown to CHAT
marked_utts = (x for x in transcript.utterances.all() if x.for_analysis)
# marked_utts = (x for x in transcript.utterances.all() if x.for_analysis)

# create mapping of query_ids to items
items_mapping = {
Expand Down
3 changes: 2 additions & 1 deletion backend/annotations/writers/saf_xlsx.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
from annotations.utils import autosize_columns, cast_to_bool, format_worksheet, get_max_words, ljust
from natsort import natsorted


@dataclass
class SAFWriter():
method: Method
Expand Down Expand Up @@ -108,7 +109,7 @@ def _make_levels_rows(self, ws: Worksheet) -> None:
all_levels = self.method_category.levels + [SAF_COMMENT_LEVEL]

for utt_id, words in natsorted(self.results.allutts.items(),
key=lambda x: x[0]):
key=lambda x: x[0]):
ws.append(self._uttlevel_row(utt_id, words))
for level in all_levels:
level_row = ljust([utt_id, level], row_size)
Expand Down
2 changes: 2 additions & 0 deletions backend/parse/tests/parse_tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,10 @@

from parse.parse_utils import corpus2alpino_parse
from lxml import etree
import pytest


@pytest.mark.skip(reason="need to figure out c2a uttids")
def test_c2a_parse(testfiles_dir, tmp_path):
infile = op.join(testfiles_dir, 'ASTA', 'single_utt', 'single_utt.cha')
outfile = op.join(tmp_path, 'single_utt.xml')
Expand Down
1 change: 1 addition & 0 deletions backend/sasta/settings.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import os
# flake8: noqa: F403
from sasta.common_settings import *

BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
Expand Down
1 change: 1 addition & 0 deletions backend/sasta/urls.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ def trigger_error(request):
division_by_zero = 1 / 0
return division_by_zero


api_router = routers.DefaultRouter() # register viewsets with this router
api_router.register(r'upload_files', analysis_views.UploadFileViewSet)
api_router.register(r'transcripts', analysis_views.TranscriptViewSet)
Expand Down
15 changes: 9 additions & 6 deletions frontend/.browserslistrc
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,15 @@
# For additional information regarding the format and rule options, please see:
# https://github.com/browserslist/browserslist#queries

# For the full list of supported browsers by the Angular framework, please see:
# https://angular.io/guide/browser-support

# You can see what browsers were selected by your queries by running:
# npx browserslist

defaults
Chrome >=60
Firefox >=63
Edge >=79
Safari >=13
iOS >=13
last 2 Chrome versions
last 1 Firefox version
last 2 Edge major versions
last 2 Safari major versions
last 2 iOS major versions
Firefox ESR
3 changes: 2 additions & 1 deletion frontend/src/app/core/core.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,11 @@ import { MenuComponent } from './menu/menu.component';
import { HomeComponent } from './home/home.component';
import { FooterComponent } from './footer/footer.component';
import { SharedModule } from '../shared/shared.module';
import { RouterModule } from '@angular/router';

@NgModule({
declarations: [MenuComponent, HomeComponent, FooterComponent],
imports: [CommonModule, SharedModule],
imports: [CommonModule, SharedModule, RouterModule],
exports: [MenuComponent, HomeComponent, FooterComponent],
})
export class CoreModule {}
8 changes: 5 additions & 3 deletions frontend/src/app/core/home/home.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -31,13 +31,15 @@ <h1>Pipeline</h1>
developed</a>, consisting of the following tools:
<p>
<ul>
<li>TT (ITSLanguage): TT supports the linguist in transcribing an uploaded audio or video fragment containing
<li><a href="https://transcribe.itslanguage.nl/" target="_blank">ITS Transcription</a> (ITSLanguage): TT supports the
linguist in transcribing an uploaded audio or video fragment containing
spontaneous language in CHAT format using automatic speech recognition.</li>
<li>SASTA (Utrecht University): SASTA analyzes a transcript grammatically and can recognize a significant number
of forms of deviant language use and analyze them correctly, following multiple assessment methods available
for Dutch (TARSP, STAP and ASTA).</li>
<li>Stamper (Anouk Scheffer, PhD candidate at Utrecht University/Auris): Stamper analyzes SASTA's output, by
<li><a href="https://grammatica.loudly.nl/" target="_blank">Stamper</a> (Anouk Scheffer, PhD candidate at Utrecht
University/Auris): Stamper analyzes SASTA's output, by
grouping various structures and making easy-to-use overviews.</li>
</ul>

</div>
</div>
3 changes: 2 additions & 1 deletion frontend/src/app/core/home/home.component.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';

import { HomeComponent } from './home.component';
import { HttpClientTestingModule } from '@angular/common/http/testing';
import { RouterTestingModule } from '@angular/router/testing';

describe('HomeComponent', () => {
let component: HomeComponent;
Expand All @@ -10,7 +11,7 @@ describe('HomeComponent', () => {
beforeEach(waitForAsync(() => {
TestBed.configureTestingModule({
declarations: [HomeComponent],
imports: [HttpClientTestingModule],
imports: [HttpClientTestingModule, RouterTestingModule],
}).compileComponents();
}));

Expand Down
2 changes: 1 addition & 1 deletion frontend/src/app/transcript/upload-saf.component.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<p-dialog [header]="header()" [(visible)]="display" modal="modal" [responsive]="true" (onHide)="onClose()"
<p-dialog [header]="header()" [(visible)]="display" modal="modal" (onHide)="onClose()"
[dismissableMask]="true">

<form (submit)="upload()">
Expand Down
10 changes: 8 additions & 2 deletions frontend/src/app/transcript/upload-saf.component.spec.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
import { HttpClientTestingModule } from '@angular/common/http/testing';
import { ComponentFixture, TestBed, waitForAsync } from '@angular/core/testing';
import { MessageService } from 'primeng/api';
import { Transcript } from '@models';
import { MessageService } from 'primeng/api';

import { FontAwesomeTestingModule } from '@fortawesome/angular-fontawesome/testing';
import { UploadSafComponent } from './upload-saf.component';
import { DialogModule } from 'primeng/dialog';

describe('UploadSafComponent', () => {
let component: UploadSafComponent;
Expand Down Expand Up @@ -42,7 +44,11 @@ describe('UploadSafComponent', () => {
beforeEach(waitForAsync(() => {
TestBed.configureTestingModule({
declarations: [UploadSafComponent],
imports: [HttpClientTestingModule],
imports: [
HttpClientTestingModule,
FontAwesomeTestingModule,
DialogModule,
],
providers: [MessageService],
}).compileComponents();
}));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,15 @@ import { ComponentFixture, TestBed } from '@angular/core/testing';

import { TreeVisualizerComponent } from './tree-visualizer.component';
import { ExtractinatorService } from 'lassy-xpath';
import { FontAwesomeTestingModule } from '@fortawesome/angular-fontawesome/testing';

describe('TreeVisualizerComponent', () => {
let component: TreeVisualizerComponent;
let fixture: ComponentFixture<TreeVisualizerComponent>;

beforeEach(async () => {
await TestBed.configureTestingModule({
imports: [FontAwesomeTestingModule],
declarations: [TreeVisualizerComponent],
providers: [ExtractinatorService],
}).compileComponents();
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/environments/version.ts
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
// TODO: Compile this from toplevel package.json
export const version = '0.9.3';
export const version = '0.9.4';
6 changes: 3 additions & 3 deletions frontend/yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -3261,9 +3261,9 @@ camelcase@^5.3.1:
integrity sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==

caniuse-lite@^1.0.30001219, caniuse-lite@^1.0.30001464, caniuse-lite@^1.0.30001565:
version "1.0.30001570"
resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001570.tgz#b4e5c1fa786f733ab78fc70f592df6b3f23244ca"
integrity sha512-+3e0ASu4sw1SWaoCtvPeyXp+5PsjigkSt8OXZbF9StH5pQWbxEjLAZE3n8Aup5udop1uRiKA7a4utUk/uoSpUw==
version "1.0.30001632"
resolved "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001632.tgz"
integrity sha512-udx3o7yHJfUxMLkGohMlVHCvFvWmirKh9JAH/d7WOLPetlH+LTL5cocMZ0t7oZx/mdlOWXti97xLZWc8uURRHg==

chalk@^2.0.0, chalk@^2.4.2:
version "2.4.2"
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "sasta",
"version": "0.9.3",
"version": "0.9.4",
"description": "Annotate and analyze transcripts",
"author": "UU Digital Humanities Lab",
"license": "BSD-3-Clause",
Expand Down

0 comments on commit d5cdbba

Please sign in to comment.