iink SDK on Device


engine.createRecognitionAssetsBuilder().compile("Text", "1234567890");

java.lang.IllegalArgumentException: unsupported type of recognition asset

        at com.myscript.iink.NativeFunctions.compile(Native Method)

        at com.myscript.iink.RecognitionAssetsBuilder.compile(RecognitionAssetsBuilder.java:71)


Dear Li Perry,

Thank you for contacting us.

You are getting this error because "Text" is not a supported resource type.

When compiling resources on device, Interactive Ink SDK allows you to generate text lexicons and math grammars. You shall respectively choose "Text Lexicon" and "Math Grammar" as the target asset type for the Type argument of the compile method.

For further details, please refer to


Best regards,


那我需要支持 subset knowledge 这个类型可以么?

I need to support subset knowledge. Is that ok?

engine.createRecognitionAssetsBuilder().compile("Subset knowledge ", "1234567890");

String internalStoragePath = context.getFilesDir().getPath();

File file = new File(internalStoragePath, File.separator + "test3.res");


我调用上面的方法生成的 subset knowledge  test3.res文件,不经过重新编译打包apk直接使用,是否可行

Can I use APK directly without recompiling and packaging

Hi Li,

Thank you for your update.

It is not possible to compile a Subset Knowledge resource on-device with RecognitionAssetsBuilder.

I you want to use a Subset Knowledge resource, you must compile them with the online tool via the Developer Portal :


Best regards,


Login or Signup to post a comment
  • Support
  • Forums
  • iink SDK on Device
  • 构建自定义资源除了在线工具外另一种方法必须从Android客户端执行么?执行报错;我的参数该如何设置?