object12_5 and lock12_5 are part of the task persistence database, they will grow in size and require the continuous maintenance of the task persistence database.
These two tables object12_5 and lock12_5 are part of our runtime database - Task Persistence.
Object 12_5 table contains all run time task and event objects. So the sum of its records would tasksession12_5 records + event12_5 records, whereby the tasksessionID (from Tasksession12_5 table) = ObjectID and EventID (from Event12_5 table) = ObjectID.
Lock12_5 table will have records for each object that is currently being worked on.
As both of these tables are part of the Task Persistence database, the only way to relieve them from unwanted data is by running the garbageCollectTaskPersistence stored procedure, or in later versions of IM 12.5, the Cleanup Submitted Tasks task in the IM user interface.
Running the cleanup procedure/task will definitely reduce the tables size. The reason is : when you delete a task that completed a week ago via the cleanup, what gets deleted is the task (tasksession12_5), the task and even objects (lock12_5 note: the task was in the lock12_5 table once it was running. Now that it is completed it can be removed from this tabe). The stored proc/cleanup task will delete from all these tables.