writer.add_document(title='My document no 4', content=
    'This is my document!', path='/a', tags='four short', icon=
    '/icons/star.png')
writer.add_document(title='5th try', content=
    'This is the second example.', path='/b', tags='5 short', icon=
    '/icons/sheep.png')
writer.add_document(title='Number six is coming', content=
    'Examples are many.', path='/c', tags='short', icon='/icons/book.png')
writer.commit()
использование BufferedWriter в колбе whooshalchemy