45 Commits

Author SHA1 Message Date
d8b06e9367 Merge pull request #227 from azooKey/feat/mapped_input_style
feat: `.mapped(id)`を新たな入力スタイルとして導入し、カスタムローマ字かな変換テーブルに対応
2025-07-23 23:35:36 +09:00
988bfd3634 refactor: remove table-specific implementation 2025-07-21 18:32:22 +09:00
59cde2a2ca Merge pull request #224 from azooKey/refactor/remove_complicated_boundary_checker
refactor: 特定のローマ字かな変換テーブルを前提にした複雑な境界チェックを廃止する
2025-07-21 17:33:47 +09:00
cf6139e245 test: add tests for Template 2025-07-21 11:18:32 +09:00
80be12f3ef feat: add session CLI for dynamic user dictionary 2025-07-21 11:18:18 +09:00
2b2329d50e refactor :remove ad-hoc impl 2025-07-14 22:55:29 -07:00
d787e88efd fix: these values need BOS 2025-07-14 14:10:57 -07:00
16363be738 fix: now FullInputProcessing.swift natively works with new index system 2025-07-14 21:17:33 +09:00
02fcdd4dc1 wip: test is not passing, but commit/push it for
working in another env
2025-07-14 00:42:53 +09:00
ee17b238a2 feat: インデックスの整合性を取るためのAPIを追加 2025-07-12 01:52:59 +09:00
704fa9871f feat: Latticeの操作をconvertTargetベースのindexとinputベースのindexの二重化 2025-07-10 01:12:11 +09:00
2e61ad1638 fix: depth関連の実装を適切に修正 2025-06-29 15:01:20 +09:00
eb4e669b2b feat: typo correctionの枝刈りを実装し、direct入力のケースでTestFullConversionの実行速度が1.6倍に向上 2025-06-29 12:30:34 +09:00
d20f4210c3 refactor: rename api 2025-06-29 01:53:19 +09:00
74d4d412c3 refactor: 辞書検索関連の関数の実装を統合し、名前を整理 (#209)
* perf: 同じloudsに対する検索をバルク処理することによって、処理の効率化を実現

* fix: bug

* test: add typo correction test

* chore: finalize imp;

* feat: update search-related impls
2025-06-27 23:21:11 +09:00
2569d8475e fix: forget memoryの実装を「粗い」チェックに変更し、表層形の一致のみで判断するようにした 2025-06-02 22:32:17 +09:00
b9cd6833da chore: remove comment 2025-06-01 21:47:23 +09:00
13a7cfad96 feat: add test for TemporalLearningMemoryTrie 2025-06-01 21:44:31 +09:00
7af6d81ef6 feat: add forget memory test 2025-06-01 21:39:33 +09:00
53cb1e3b41 fix: update tests 2025-06-01 21:02:27 +09:00
750d9f87e4 fix: fix failed tests and update for clarity 2025-06-01 20:31:36 +09:00
96b0bcce53 Merge branch 'develop' into codex/modify-learningmanager.init-and-add-error-handling 2025-06-01 20:26:39 +09:00
5a4b3e728e test: verify pause file recovery 2025-05-25 19:36:11 +09:00
5e58458895 Add comma separated number special candidate 2025-05-25 18:40:18 +09:00
eb040124e7 fix: add more test cases 2025-03-30 17:20:07 +09:00
e8f9eb2f80 Update testConvertToTimeExpression to use await for KanaKanjiConverter initialization
* Change `let converter = KanaKanjiConverter()` to `let converter = await KanaKanjiConverter()`
2025-03-30 16:58:10 +09:00
feb5daa5bb Update convertToTimeExpression function to handle edge cases and correct time validation
* **TimeExpression.swift**
  - Change the validation for 3-digit numbers to allow last two digits between 00-59.
  - Change the validation for 4-digit numbers to allow first two digits between 00-24 and last two digits between 00-59.

* **TimeExpressionTests.swift**
  - Update test cases to reflect the new validation rules.
  - Change test input "1360" to "2440" and update expected results accordingly.
  - Update assertions for the modified test cases.
2025-03-30 16:57:46 +09:00
19dbbccd9f Add test cases for convertToTimeExpression function
* **Test cases**
  - Create `KanaKanjiConverter` instance
  - Use `makeDirectInput` to create `ComposingText` instances for test cases
  - Call `convertToTimeExpression` function with different inputs
  - Verify the results using `XCTAssertEqual` and `XCTAssertTrue`

* **Helper function**
  - Add `makeDirectInput(direct input: String) -> ComposingText` helper function

* **Concurrency**
  - Use `await` for the call of `convertToTimeExpression`
  - Call `convertToTimeExpression` outside of XCTest function
2025-03-30 16:55:34 +09:00
65ac2fa3aa Update testConvertToTimeExpression function to use await for convertToTimeExpression calls
* Ensure `convertToTimeExpression` function is called asynchronously in all test cases
2025-03-30 16:48:17 +09:00
ac8dfc8dc3 Update test cases for current convertToTimeExpression signature
* Add makeDirectInput function to create ComposingText instances
* Update testConvertToTimeExpression to use makeDirectInput for input conversion
2025-03-30 16:44:45 +09:00
3b6d63c8d3 Add async/await to test functions in TimeExpressionTests.swift
* **testConvertToTimeExpression**
  - Change function signature to `async throws`
  - Initialize `KanaKanjiConverter` with `await`

* **testToTimeExpressionCandidates**
  - Change function signature to `async throws`
  - Initialize `KanaKanjiConverter` with `await`
2025-03-30 16:38:22 +09:00
ad580d5214 feat: Add time expression conversion function
Fixes #170

Add functionality to convert 3-digit and 4-digit numbers into time expressions in the format 'HH:MM'.

* Add `convertToTimeExpression` function in `Sources/KanaKanjiConverterModule/Converter/TimeExpression.swift` to handle the conversion.
* Modify `Sources/KanaKanjiConverterModule/Converter/KanaKanjiConverter.swift` to include the new function and call it within `getWiseCandidate`.
* Add tests in `Tests/KanaKanjiConverterModuleTests/ConverterTests/TimeExpressionTests.swift` to ensure the new function works correctly.

---

For more details, open the [Copilot Workspace session](https://copilot-workspace.githubnext.com/azooKey/AzooKeyKanaKanjiConverter/issues/170?shareId=XXXX-XXXX-XXXX-XXXX).
2025-03-30 16:32:25 +09:00
e5214c3d5c feat: Enhance email address conversion feature
Fixes #75

Enhance the email address conversion feature to filter suggestions based on partial domain inputs.

* Update `toEmailAddressCandidates` function in `Sources/KanaKanjiConverterModule/Converter/EmailAddress.swift` to filter suggestions based on the characters before '@'.
* Add logic to check if the input ends with '@' and filter the suggestions based on the characters before '@'.
* Generate suggestions for email domains that match the partial domain input.
* Add tests in `Tests/KanaKanjiConverterModuleTests/ConverterTests/EmailAddressConversionTests.swift` to verify the new filtering functionality for partial domain inputs like '@g' and '@y'.

---

For more details, open the [Copilot Workspace session](https://copilot-workspace.githubnext.com/ensan-hcl/AzooKeyKanaKanjiConverter/issues/75?shareId=XXXX-XXXX-XXXX-XXXX).
2025-02-09 00:14:32 +09:00
55ffe3c708 [Experimental] Zenzai (#92)
* experimental rinna integration

* Update impl

* update

* Bump swift-actions/setup-swift from 1 to 2

Bumps [swift-actions/setup-swift](https://github.com/swift-actions/setup-swift) from 1 to 2.
- [Release notes](https://github.com/swift-actions/setup-swift/releases)
- [Commits](https://github.com/swift-actions/setup-swift/compare/v1...v2)

---
updated-dependencies:
- dependency-name: swift-actions/setup-swift
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* change test

* change impl

* take gpt2 weight as option

* don't use async

* support status check

* enhance error

* avoid percent encode

* update

* GPT-2 based kana-kanji conversion is now perfectly workinggit statusgit status

* fix a bug

* Rename gpt2/llama -> zenz

* cleanup

* internal apiを綺麗にした

* cleanup experimental commands

* update

* partially support incremental input using cache

* fix names

* fix bug

* support roman2kana

* cleanup

* fix minor bugs

* improve logic

* fix minor bug

* fix minor bug

* fix minor bug

* optimize

* optimize performance

* Optimize cache hit

* cli: add anco session command

* fix cache hit bugs

* improve session commands

* maybe this will work better for incremental input environment

* speed up zenzai by using n_best alternatives

* update zenz context

* adding no_typo api

* add inference limit

* fix bug

* reset install_cli

* make package buildable -- but llama.cpp features just do not work at this point because metal is not preprocessed

* add proper availability checks

* change macOS minimum version

* fix several problems

* code cleanup

* enable ubuntu build

* fix build error

* fix ubuntu build

* fix borrowing

* update install_cli.sh

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-15 01:36:45 +09:00
861ac7a026 feat: MetadataのAPIをより柔軟にした (#89) 2024-05-04 11:56:09 +09:00
0795b8cf84 [Experimental] ConvertGraphを実装し、その上での完全一致変換を実装 (#47)
* ConvertGraphを実装し、その上での完全一致変換を実装

* 名前空間を汚染していたので修正

* Implementation completed (without test)

* move directory to use default dictionary

* fix implementations to enable conversion

* add test cases

* Backward searchで発見された候補を明示的に削除

* fix tests

* simplify
2024-02-24 23:21:44 +09:00
52fc9ae4c2 [Experimental] InputGraphの構造を変更し、LookupGraphによる辞書引きを実装 (#46)
* implement byfix lookup

* find failing test

* implement backward search

* add more test cases

* add new file

* split files

* Improve InputGraph Architecture

* implement dictionary search
2024-02-23 17:51:27 +09:00
784a80c46a [Experimental] InputGraphベースの辞書ルックアップ (#45) 2024-02-23 02:37:59 +09:00
5431bafb27 [WIP] InputGraphベースの入力管理の実装 (#44)
* Test-level implementation of InputGraph

* move file

* implement typo-sensitiveness

* implement input style and input style boundary checking

* fix ci

* fix ci 2
2024-02-22 16:56:22 +09:00
76d511d3dd switch to async test instead of mainactor testcases 2024-02-19 23:30:32 +09:00
c156f16b9e lint 2023-08-16 18:43:43 +09:00
5c01280fca lint 2023-08-16 18:42:53 +09:00
2a240df7c3 fix template parse logic 2023-08-16 18:38:50 +09:00
aad755da6f Support Strict concurrency 2023-07-23 18:48:20 +09:00
98bc180c17 Move to root 2023-07-23 00:34:27 +09:00